TP5 only - removed TP4 support

This commit is contained in:
Jaromir 2016-04-20 22:59:21 +02:00
Родитель 80c4e1459a
Коммит 10c67d4aef
3 изменённых файлов: 18 добавлений и 88 удалений

Просмотреть файл

@ -266,55 +266,11 @@ if (Test-Path -Path $ServerMediaPath'\nanoserver\Packages\en-us\*en-us*'){
}else{ }else{
#TP4 Version Write-Host "`t Please use Windows Server TP5 and newer. Exiting" -ForegroundColor Red
Convert-WindowsImage -SourcePath $ServerMediaPath'\Nanoserver\NanoServer.wim' -edition 1 -VHDPath $workdir'\ParentDisks\Win2016Nano_G2.vhdx' -SizeBytes 30GB -VHDFormat VHDX -DiskLayout UEFI Write-Host "Press any key to continue ..."
&"$workdir\Temp\dism\dism" /Mount-Image /ImageFile:$workdir\Parentdisks\Win2016Nano_G2.vhdx /Index:1 /MountDir:$workdir\Temp\mountdir $host.UI.RawUI.ReadKey("NoEcho,IncludeKeyDown") | OUT-NULL
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-NanoServer-DSC-Package.cab /Image:$workdir\Temp\mountdir $HOST.UI.RawUI.Flushinputbuffer()
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-NanoServer-DSC-Package.cab /Image:$workdir\Temp\mountdir Exit
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-NanoServer-FailoverCluster-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-NanoServer-FailoverCluster-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-NanoServer-Guest-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-NanoServer-Guest-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-NanoServer-Storage-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-NanoServer-Storage-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-Windows-Server-SCVMM-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-Windows-Server-SCVMM-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Unmount-Image /MountDir:$workdir\Temp\mountdir /Commit
Copy-Item -Path "$workdir\Parentdisks\Win2016Nano_G2.vhdx" -Destination "$workdir\ParentDisks\Win2016NanoHV_G2.vhdx"
 
&"$workdir\Temp\dism\dism" /Mount-Image /ImageFile:$workdir\Parentdisks\Win2016NanoHV_G2.vhdx /Index:1 /MountDir:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-NanoServer-Compute-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-NanoServer-Compute-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-Windows-Server-SCVMM-Compute-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-Windows-Server-SCVMM-Compute-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Unmount-Image /MountDir:$workdir\Temp\mountdir /Commit
Copy-Item -Path "$workdir\ParentDisks\Win2016NanoHV_G2.vhdx" -Destination "$workdir\ParentDisks\Win2016NanoHVRF_G2.vhdx"
&"$workdir\Temp\dism\dism" /Mount-Image /ImageFile:$workdir\Parentdisks\Win2016NanoHVRF_G2.vhdx /Index:1 /MountDir:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\Microsoft-OneCore-ReverseForwarders-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$workdir\Temp\packages\en-us\Microsoft-OneCore-ReverseForwarders-Package.cab /Image:$workdir\Temp\mountdir
&"$workdir\Temp\dism\dism" /Unmount-Image /MountDir:$workdir\Temp\mountdir /Commit
#do some servicing
'Win2016Core_G2.vhdx','Win2016Nano_G2.vhdx','Win2016NanoHV_G2.vhdx','Win2016NanoHVRF_G2.vhdx' | ForEach-Object {
&"$workdir\Temp\dism\dism" /Mount-Image /ImageFile:$workdir\Parentdisks\$_ /Index:1 /MountDir:$workdir\Temp\mountdir
$ServerPackages | ForEach-Object {
$packagepath=$_.FullName
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$packagepath /Image:$workdir\Temp\mountdir
}
&"$workdir\Temp\dism\dism" /Unmount-Image /MountDir:$workdir\Temp\mountdir /Commit
}
If ($LabConfig.CreateClientParent -eq "Yes"){
&"$workdir\Temp\dism\dism" /Mount-Image /ImageFile:$workdir\Parentdisks\Win10_G2.vhdx /Index:1 /MountDir:$workdir\Temp\mountdir
$ClientPackages | ForEach-Object {
$packagepath=$_.FullName
&"$workdir\Temp\dism\dism" /Add-Package /PackagePath:$packagepath /Image:$workdir\Temp\mountdir
}
&"$workdir\Temp\dism\dism" /Unmount-Image /MountDir:$workdir\Temp\mountdir /Commit
}
} }
#create Tools VHDX #create Tools VHDX

Просмотреть файл

@ -4,20 +4,20 @@ $LabConfig=@{AdminPassword='LS1setup!'; DomainAdminName='Ned'; Prefix = 'SDSWS-'
$NetworkConfig=@{SwitchName = 'LabSwitch' ; StorageNet1='172.16.1.'; StorageNet2='172.16.2.'} $NetworkConfig=@{SwitchName = 'LabSwitch' ; StorageNet1='172.16.1.'; StorageNet2='172.16.2.'}
$LAbVMs = @( $LAbVMs = @(
#TP4 Storage Spaces Direct scenario #Storage Spaces Direct scenario
@{VMName = 'Direct1' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB }, @{VMName = 'Direct1' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB },
@{VMName = 'Direct2' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB }, @{VMName = 'Direct2' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB },
@{VMName = 'Direct3' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB }, @{VMName = 'Direct3' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB },
@{VMName = 'Direct4' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB }, @{VMName = 'Direct4' ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB },
#TP4 Shared Storage Spaces scenario #Shared Storage Spaces scenario
@{ VMName = 'Shared1' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'}, @{ VMName = 'Shared1' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'},
@{ VMName = 'Shared2' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'}, @{ VMName = 'Shared2' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'},
@{ VMName = 'Shared3' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'}, @{ VMName = 'Shared3' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'},
@{ VMName = 'Shared4' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'}, @{ VMName = 'Shared4' ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'},
#TP4 Shared Storage for Storage Replica #Shared Storage for Storage Replica
@{ VMName = 'Replica1' ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'}, @{ VMName = 'Replica1' ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'},
@{ VMName = 'Replica2' ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'}, @{ VMName = 'Replica2' ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'},
@{ VMName = 'Replica3' ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet2' ; StorageNetwork = 'Yes'}, @{ VMName = 'Replica3' ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet2' ; StorageNetwork = 'Yes'},
@ -72,7 +72,6 @@ ParentVHD
Win2016Core_G2.vhdx - Windows Server 2016 Core Win2016Core_G2.vhdx - Windows Server 2016 Core
Win2016Nano_G2.vhdx - Windows Server 2016 Nano with these packages: DSC, Failover Cluster, Guest, Storage, SCVMM Win2016Nano_G2.vhdx - Windows Server 2016 Nano with these packages: DSC, Failover Cluster, Guest, Storage, SCVMM
Win2016NanoHV_G2.vhdx - Windows Server 2016 Nano with these packages: DSC, Failover Cluster, Guest, Storage, SCVMM, Compute, SCVMM Compute Win2016NanoHV_G2.vhdx - Windows Server 2016 Nano with these packages: DSC, Failover Cluster, Guest, Storage, SCVMM, Compute, SCVMM Compute
Win2016NanoHVRF_G2.vhdx - Windows Server 2016 Nano with these packages: DSC, Failover Cluster, Guest, Storage, SCVMM, Compute, SCVMM Compute, Reverse Forwarders (removed in TP5 as RF are always in nano)
Win10_G2.vhdx - Windows 10 if you selected to hydrate it with create client parent. Win10_G2.vhdx - Windows 10 if you selected to hydrate it with create client parent.
StorageNetwork StorageNetwork
@ -104,14 +103,6 @@ SkipDjoin
### more Dynamic examples ### ### more Dynamic examples ###
<# More Dynamic examples of the same configuration as above. But now you can deploy thousands VMs with simple change. So instead of 1..4 use 1..1000 <# More Dynamic examples of the same configuration as above. But now you can deploy thousands VMs with simple change. So instead of 1..4 use 1..1000
$LAbVMs = @()
1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } }
1..4 | % {"Shared$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'} }
1..2 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'} }
3..4 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet2' ; StorageNetwork = 'Yes'} }
# vnext version
$LAbVMs = @() $LAbVMs = @()
1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } } 1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } }
1..4 | % {"Shared$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'} } 1..4 | % {"Shared$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1' ; StorageNetwork = 'Yes'} }
@ -122,6 +113,7 @@ $LAbVMs = @()
### LABVMs Examples ### ### LABVMs Examples ###
<# <#
Just some VMs Just some VMs
$LAbVMs = @( $LAbVMs = @(
@{ VMName = 'Simple1' ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB }, @{ VMName = 'Simple1' ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB },
@ -129,13 +121,12 @@ $LAbVMs = @(
@{ VMName = 'Simple3' ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB }, @{ VMName = 'Simple3' ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB },
@{ VMName = 'Simple4' ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB } @{ VMName = 'Simple4' ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB }
) )
or you can use this to deploy 100 simple VMs
or you can use this to deploy 100 simple VMs
$LAbVMs = @() $LAbVMs = @()
1..100 | % {"Simple$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB } } 1..100 | % {"Simple$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB } }
or you can use this to deploy 100 simple VMs with 1 management Client OS or you can use this to deploy 100 simple VMs with 1 management Client OS
$LAbVMs = @() $LAbVMs = @()
1..100 | % {"Simple$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB } } 1..100 | % {"Simple$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016Nano_G2.vhdx' ; MemoryStartupBytes= 512MB } }
$LAbVMs += @{ VMName = 'Management' ; Configuration = 'Simple' ; ParentVHD = 'Win10_G2.vhdx' ; MemoryStartupBytes= 512MB ; AddToolsVHD='Yes' } $LAbVMs += @{ VMName = 'Management' ; Configuration = 'Simple' ; ParentVHD = 'Win10_G2.vhdx' ; MemoryStartupBytes= 512MB ; AddToolsVHD='Yes' }
@ -150,50 +141,27 @@ Hyperconverged S2D with nano and nested virtualization (see https://msdn.microso
$LAbVMs = @() $LAbVMs = @()
1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 4GB ; NestedVirt='Yes'} } 1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 4GB ; NestedVirt='Yes'} }
HyperConverged Storage Spaces Direct with Nano Server HyperConverged Storage Spaces Direct with Nano Server
$LAbVMs = @() $LAbVMs = @()
1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB ; StorageNetwork = 'Yes'} } 1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } }
vnext
$LAbVMs = @()
1..4 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB ; StorageNetwork = 'Yes'} }
Disaggregated Storage Spaces Direct with Nano Server Disaggregated Storage Spaces Direct with Nano Server
$LAbVMs = @() $LAbVMs = @()
1..4 | % {"Compute$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; MemoryStartupBytes= 512MB } } 1..4 | % {"Compute$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; MemoryStartupBytes= 512MB } }
1..4 | % {"SOFS$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 12; SSDSize=800GB ; HDDNumber = 0 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } } 1..4 | % {"SOFS$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 12; SSDSize=800GB ; HDDNumber = 0 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } }
vnext
$LAbVMs = @()
1..4 | % {"Compute$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; MemoryStartupBytes= 512MB } }
1..4 | % {"SOFS$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 12; SSDSize=800GB ; HDDNumber = 0 ; HDDSize= 4TB ; MemoryStartupBytes= 512MB } }
"traditional" stretch cluster (like with traditional SAN) "traditional" stretch cluster (like with traditional SAN)
$LAbVMs = @() $LAbVMs = @()
1..2 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'} }
3..4 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHVRF_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet2' ; StorageNetwork = 'Yes'} }
vnext
$LAbVMs = @()
1..2 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'} } 1..2 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet1' ; StorageNetwork = 'Yes'} }
3..4 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet2' ; StorageNetwork = 'Yes'} } 3..4 | % {"Replica$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Replica' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; ReplicaHDDSize = 20GB ; ReplicaLogSize = 10GB ; MemoryStartupBytes= 2GB ; VMSet= 'ReplicaSet2' ; StorageNetwork = 'Yes'} }
Stretch cluster with Storage Spaces Direct Stretch cluster with Storage Spaces Direct
$LAbVMs = @() $LAbVMs = @()
1..8 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 2GB } } 1..8 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 2GB } }
vnext
$LAbVMs = @()
1..8 | % {"Direct$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'S2D' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 4; SSDSize=800GB ; HDDNumber = 12 ; HDDSize= 4TB ; MemoryStartupBytes= 2GB } }
HyperConverged Storage Spaces with Shared Storage HyperConverged Storage Spaces with Shared Storage
$LAbVMs = @() $LAbVMs = @()
1..4 | % {"Compute$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; MemoryStartupBytes= 512MB } } 1..4 | % {"Compute$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Simple' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; MemoryStartupBytes= 512MB } }
1..4 | % {"SOFS$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1'} } 1..4 | % {"SOFS$_"} | % { $LAbVMs += @{ VMName = $_ ; Configuration = 'Shared' ; ParentVHD = 'Win2016NanoHV_G2.vhdx' ; SSDNumber = 6; SSDSize=800GB ; HDDNumber = 8 ; HDDSize= 1TB ; MemoryStartupBytes= 512MB ; VMSet= 'SharedLab1'} }
....
#> #>

Просмотреть файл

@ -26,7 +26,13 @@
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
</PropertyGroup> </PropertyGroup>
<ItemGroup /> <ItemGroup>
<Compile Include="1_Prereq.ps1" />
<Compile Include="2_CreateParentDisks.ps1" />
<Compile Include="3_Deploy.ps1" />
<Compile Include="Cleanup.ps1" />
<Compile Include="Variables.ps1" />
</ItemGroup>
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<Target Name="Build" /> <Target Name="Build" />
</Project> </Project>