mirror of
https://github.com/jamesstringerparsec/Easy-GPU-PV.git
synced 2024-08-30 18:22:17 +00:00
Set VM configuration version to maximum
This commit is contained in:
parent
ad1e7fffb1
commit
11648360a9
@ -4297,8 +4297,9 @@ param(
|
||||
[string]$autologon
|
||||
)
|
||||
Modify-AutoUnattend -username "$username" -password "$password" -autologon $autologon -hostname $VMName -UnattendPath $UnattendPath
|
||||
$MaxAvailableVersion = (Get-VMHostSupportedVersion).Version | Select-Object -Last 1
|
||||
Convert-WindowsImage -SourcePath $SourcePath -Edition $Edition -VHDFormat $Vhdformat -VHDPath $VhdPath -DiskLayout $DiskLayout -UnattendPath $UnattendPath -GPUName $GPUName -Team_ID $Team_ID -Key $Key -SizeBytes $SizeBytes| Out-Null
|
||||
New-VM -Name $VMName -MemoryStartupBytes $MemoryAmount -VHDPath $VhdPath -Generation 2 -SwitchName "Default Switch" | Out-Null
|
||||
New-VM -Name $VMName -MemoryStartupBytes $MemoryAmount -VHDPath $VhdPath -Generation 2 -SwitchName "Default Switch" -Version $MaxAvailableVersion | Out-Null
|
||||
Set-VM -Name $VMName -ProcessorCount $CPUCores -CheckpointType Disabled -LowMemoryMappedIoSpace 3GB -HighMemoryMappedIoSpace 32GB -GuestControlledCacheTypes $true -AutomaticStopAction ShutDown
|
||||
Set-VMMemory -VMName $VMName -DynamicMemoryEnabled $false
|
||||
Set-VMProcessor -VMName $VMName -ExposeVirtualizationExtensions $true
|
||||
|
Loading…
Reference in New Issue
Block a user