Quantcast
Channel: Rob V IT
Viewing all articles
Browse latest Browse all 64

How to: Create Nano server image

$
0
0

With Server 2016 TP5 available today, we want to test it by ourselves.
First; how-to deploy a Nano server image.

Download the server 2016 ISO and mount it.

  1. Launch PowerShell as Administrator.
  2. Copy Nano server folder with the following command:
    Copy-Item -Path E:\NanoServer\ -Destination C:\NanoServer\ -Recurse
  3. Import the PowerShell module for building the the image with the following command:
    Set-Location –Path C:\NanoServer 
    Import-Module .\NanoServerImageGenerator\NanoServerImageGenerator.psd1
  1. Run command
    Show-Command New-NanoServerImage

Gives a GUI where you can give the parameters for deploying the nano server VHD.
* Note: When you select other roles you must use the -Mediapath variable to the ISO.
** Note: AdministratorPassword must be a secure string. In the GUI Password field: (ConvertTo-SecureString -String “YourPassword” -AsPlainText -Force)

In order to automate things you can also do it by hand:

#Example usage for virtual nano server

Import-Module D:\NanoServer\NanoServerImageGenerator\NanoServerImageGenerator.psd1

$NanoHash = @{
Compute = $True
Clustering = $True
EnableRemoteManagementPort = $True
Container = $True
AdministratorPassword = (ConvertTo-SecureString -String "Welkom01" -AsPlainText -Force)
DeploymentType = "Guest"
Edition = "Datacenter"
Computername = "NANO01"
MediaPath = "E:\"
BasePath = "D:\NanoServer\"
TargetPath = "D:\NanoServer\NANO01.vhdx"
DomainName = "contoso.com"
IPv4Address = "192.168.1.10"
IPv4SubnetMask = "255.255.255.0"
IPv4Gateway = "192.168.1.1"
InterfaceNameOrIndex = "Ethernet"


}

New-NanoServerImage @nanoHash

 


Viewing all articles
Browse latest Browse all 64

Trending Articles