Nano Server.

By | 8 October, 2015

I’ve been attempting for days to get a VHD of Nano Server (Windows 2016 TP3) up and running from the instructions on Microsoft and on the Microsoft Virtual Academy. I’ve been having issues with the new-nanoserverimage.ps1 just quitting and not giving any error text
back. I knew it wasn’t working as the image wasn’t getting created.

….so what was wrong. Lets go through the steps slowly.

We start off with a vanilla Windows 10 Client (running physically, I am going to try it in a virtual later to see if that would make any difference. EDIT: Does work).

Grab the TP3 ISO from Microsoft Insider Program. Mines called 10514.0.150808-1529.TH2_RELEASE_SERVER_OEMRET_X64FRE_EN-US.ISO

Windows 10 will let me mount that iso as a virtual drive simply by double clicking it.

Once mounted, go into the “CD” and copy the \nanoServer directory to a folder on the Windows 10 client. I put mine in c:\NanoServer.

So in that directory we should see:


09/08/2015  09:53           206,093 convert-windowsimage.ps1
08/10/2015  22:35    DIR            NanoServer
09/08/2015  09:53       123,734,695 NanoServer.wim
09/08/2015  09:53            50,977 new-nanoserverimage.ps1
08/10/2015  23:02                 0 new.txt
08/10/2015  22:36     DIR           Packages
09/08/2015  09:53               116 ReadMe.txt

Now here where’s we need to be careful and where I’ve been batting my head against a brick wall.

1. Open a powershell command prompt (right clicking, Run As Administrator)

2. cd into the c:\nanoServer directory.

3. Now, we do something called “dot sourcing” the two powershell scripts. This means the contents of those scripts is loaded into memory. There are a variety of functions and methods that are needed. We do this by:

. .\new-nanoserverimage.ps1
. .\convert-windowsimage.ps1

4. Here was my mistake…. watch the next command carefully.

PS C:\nanoServer> new-nanoserverimage -MediaPath d:\ -BasePath .\Base -TargetPath .\Target -ComputerName ‘Nano1’ -language en-us -GuestDrivers

The mistake was that we’re not calling the new-nanoserverimage.ps1 in the command, we’re actually calling a function inside that script thats been loaded.

If its been successful, the Base folder, the Target folder should get created automatically and those folders should contain a vhd image in each. Note the “-language en-us”. This tells the install to use the us language package. Since its only a tech preview, MS is only providing en-us.

What does success look like:

Windows(R) Image to Virtual Hard Disk Converter for Windows(R) 10
Copyright (C) Microsoft Corporation. All rights reserved.
Version 10.0.9000.0.amd64fre.fbl_core1_hyp_dev(mikekol).141224-3000 Beta

INFO : Image 1 selected ()…
INFO : Creating sparse disk…
INFO : Attaching VHD…
INFO : Disk initialized with MBR…
INFO : Disk partitioned…
INFO : Volume formatted…
INFO : Access path (F:\) has been assigned…
INFO : Applying image to VHD. This could take a while…
INFO : Signing disk…
INFO : Image applied. Making image bootable…
INFO : Fixing the Device ID in the BCD store on VHD…
INFO : Drive is bootable. Cleaning up…
INFO : Closing VHD…

INFO : Closing Windows image…

…and we’re done. Mount in your VM host of choice. I’m just about to try it in VirtualBox….