VMware + Windows Server 2016 Technical Preview 4 Nano Server

A few weeks ago, I posted VMware + Windows Nano Server = How to build them? article based on Windows Server 2016 Nano Server Technical Preview 3 in TechNet Wiki just before an updated Technical Preview 4 is released globally.

Since Windows Server 2016 Technical Preview 4 is released on 20/11/2015, I have updated the article with Windows Server 2016 Technical Preview 4 as a proof of concept that the technique still work with minor changes including an article title change to Windows Nano Server: Virtualization with VMware vSphere by Peter Geelen.

So what has changed between Technical Preview 3 and Technical Preview 4? Well, there are a lot of improvements made including more Nano Server functionalities and capabilities. But we shall discuss the changes on building our first Nano Server in this post and only highlight the differences.

In Technical Preview 3, we must import New-NanoServerImage.ps1 PowerShell script as a module to use the New-NanoServerImage command.

# Import New-NanoServerImage PowerShell Module
# for Technical Preview 3
Import-Module `
    -Global C:\NanoServer\new-nanoserverimage.ps1 ;

 

In Technical Preview 4, Microsoft has renamed the New-NanoServerImage.ps1 PowerShell script to NanoServerImageGenerator.psm1 PowerShell module. Therefore, we need to import this NanoServerImageGenerator.psm1 PowerShell module to get the New-NanoServerImage command.

# Import New-NanoServerImage PowerShell Module 
# for Technical Preview 4
Import-Module `
    -Global C:\NanoServer\NanoServerImageGenerator.psm1 ;

 

What else has changed? In Technical Preview 3, the New-NanoServerImage command by default will use the hostname specified in the -ComputerName parameter as the filename for the generated VHD file.

# Create New Basic NanoServer Image for Technical Preview 3
New-NanoServerImage `
    -MediaPath Z: `
    -BasePath C:\NanoServer\Base `
    -TargetPath C:\NanoServer\NanoServer `
    -ComputerName NanoServer `
    -EnableRemoteManagementPort `
    -Language 'en-us' `
    -GuestDrivers `
    -DriversPath C:\NanoServer\VMware-Drivers `
    -AdministratorPassword (ConvertTo-SecureString -String "Password" -AsPlainText -Force) ;

 

In Technical Preview 4, we need to specify the filename in the -TargetPath parameter and therefore we can call it as an improved feature which allows you to choose the filename that you want.

# Create New Basic NanoServer Image for Technical Preview 4
New-NanoServerImage `
    -MediaPath Z: `
    -BasePath C:\NanoServer\Base `
    -TargetPath C:\NanoServer\NanoServer\NanoServer.vhd `
    -ComputerName NanoServer `
    -EnableRemoteManagementPort `
    -Language 'en-us' `
    -GuestDrivers `
    -DriversPath C:\NanoServer\VMware-Drivers `
    -AdministratorPassword (ConvertTo-SecureString -String "Password" -AsPlainText -Force) ;

 

As for in Technical Preview 3, we can use a previous Nano Server VHD as a baseline and add additional role or feature to be generated as the next Nano Server image using the -ExistingVHDPath parameter. But in Technical Preview 4, -ExistingVHDPath parameter is deprecated and we cannot do that anymore. That means that we have to use the Edit-NanoServerImage command to add additional packages.

# Create a New NanoServer with Hyper-V role
# using existing NanoServer Base Image with Technical Preview 3
New-NanoServerImage `
     -MediaPath Z: `
     -BasePath C:\NanoServer\Base `
     -TargetPath C:\NanoServer\NanoServer-Compute `
     -ExistingVHDPath C:\NanoServer\NanoServer\NanoServer.vhd `
     -ComputerName NanoServer `
     -Compute `
     -EnableRemoteManagementPort `
     -Language 'en-us' `
     -GuestDrivers `
     -AdministratorPassword (ConvertTo-SecureString -String "Password" -AsPlainText -Force) ;

 

Finally, Voila… You have a WIndows Server 2016 Technical Preview 4 Nano Server in 4GB VMDK as the screenshot below after login.

VMware + Windows Nano Server - Build Process 22 - TP4 - Viewing Nano Server System Configuration