Microsoft is listening to our feedback and gives us the Generation 2 VM support for the VM role gallery item with Update Rollup 6 for VMM & WAP. Just want to mention that with VMM Update Rollup 6 Generation 2 VM support for Service Templates is also included.
The Generation 2 VM deployment settings are set on a per cloud basis. That means that you have to set a custom property on a VMM cloud to enable the specific deployment behavior. It is not a setting that you will provide within a single VM role gallery item. There for you have to split your workloads into different VMM clouds. For example one VMM cloud for Generation 1 VM workloads and another VMM cloud for Generation 2 VM workloads. Based on that model you will have as a minimum two different hosting plans in your WAP environment.
To enable the Generation 2 VM support on a VMM cloud execute the following PowerShell cmdlets on the VMM server itself or on a workstation with an installed VMM console.
Select the VMM cloud on which you would like to enable the Generation 2 VM support.
$VMMServer = vmm.domain.local
$Cloud = Get-SCCloud -VMMServer $VMMServer|Select-Object -Property Name|Out-GridView -PassThru -Title “Cloud”
$Cloud = Get-SCCloud -VMMServer $VMMServer -Name $Cloud.Name
Then you create a new custom property called SupportedVmGenerationForVmRole.
$CustomProperty = New-SCCustomProperty -VMMServer $VMMServer -Name “SupportedVmGenerationForVmRole” -Description “Deploy Gen2 VM roles” -AddMember @(“Cloud”)
The last step is to set the custom property value to 2, if you want the Generation 2 VM deployment. Otherwise set the value to 1 to keep the default Generation 1 VM deployment.
Set-SCCustomPropertyValue -CustomProperty $CustomProperty -InputObject $Cloud -Value “2”