Skip navigation
Create a new Nano Server image with 2016 RTM

Create a new Nano Server image with 2016 RTM

Q. What are the commands to create a new Nano Server image using Windows Server 2016 RTM?

A. The PowerShell below creates a new Generation 1 (VHD) disk to be used with Hyper-V. In this example I add Storage, DSC, Windows Defender and add remote management support. It is deployed as Standard edition SKU. It is also joining a domain using an existing AD account.

$adminPass = ConvertTo-SecureString "Pa55word" -AsPlainText -Force
$NanoVHDPath = ".\NanoServerVM.vhd"

import-module D:\NanoBuild\NanoServerImageGenerator.psm1

New-NanoServerImage -MediaPath 'S:\OS Images\Windows Server 2016 RTM\Expanded' `
-BasePath .\Base -TargetPath $NanoVHDPath -ComputerName NanoVM `
-DeploymentType Guest -Edition Standard `
-Storage -Defender -EnableRemoteManagementPort `
-Package Microsoft-NanoServer-DSC-Package `
-UnattendPath .\unattend.xml `
-AdministratorPassword $adminPass -DomainName savilltech -ReuseDomainNode

 

Hide comments

Comments

  • Allowed HTML tags: <em> <strong> <blockquote> <br> <p>

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
Publish