Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

We will be required to enable singlePlacementGroup even though you have not enabled AutomaticRepairsPolicy when we deploying VMSS using New-AzVmss. #11257

Closed
koyasuda-msft opened this issue Mar 6, 2020 · 13 comments
Assignees
Labels
Compute - VMSS customer-reported Service Attention This issue is responsible by Azure service team.

Comments

@koyasuda-msft
Copy link

Description

When we deploy new VMSS under APPGW whose health prove is enabled, the error message is occurred.
I don't choose " -EnableAutomaticRepair " option in "New-AzVmssConfig".
However, the error message tells me that you should enable "singlePlacementGroup" to deply VMSS.

When I tried in Ver Az 1.1.0, same error is not occurred.
I and Cx confirmed that same error is occurred in Az 3.5.0 and 3.1.0.
I think that this reason is "Automatic repairs feature" is newer function.

PS C:\Users\koyasuda> Get-InstalledModule -Name Az -AllVersions | select Name,Version

Name Version


Az 1.1.0
Az 3.5.0

when I deployed single VMSS(not under APPGW), the same error is not occurred.

Steps to reproduce

I attached my scripts.

==========================

$vnet = Get-AzVirtualNetwork -ResourceGroupName $rgname
-Name $vnet.Name

$appgw = Get-AzApplicationGateway -ResourceGroupName $rgname
-Name $appgwName

$backendPool = Get-AzApplicationGatewayBackendAddressPool -Name $defaultPool.Name
-ApplicationGateway $appgw

$ipConfig = New-AzVmssIpConfig -Name $gipconfig.Name
-SubnetId $vnet.Subnets[0].Id `
-ApplicationGatewayBackendAddressPoolsId $backendPool.Id

$vmssConfig = New-AzVmssConfig -Location japaneast
-SkuCapacity 2 -SkuName Standard_DS2_v2
-UpgradePolicyMode Automatic `
-Zone @("1", "2", "3")

$vmImage = Get-AzImage -ResourceGroupName $rgname -ImageName $vmImageName

Set-AzVmssStorageProfile $vmssConfig -ImageReferenceId $vmImage.Id -OsDiskCreateOption "FromImage"

Set-AzVmssOsProfile $vmssConfig -AdminUsername $vmssAdminUserName
-AdminPassword $vmssAdminPassword `
-ComputerNamePrefix $scaleSetName

Add-AzVmssNetworkInterfaceConfiguration -VirtualMachineScaleSet $vmssConfig
-Name "NetConfig" -Primary $true
-IPConfiguration $ipConfig

New-AzVmss -ResourceGroupName $rgname -Name $scaleSetName -VirtualMachineScaleSet $vmssConfig -Debug

Environment data

PS C:\Users\koyasuda> $PSVersionTable

Name Value


PSVersion 5.1.18362.628
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.18362.628
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

Module versions

ModuleType Version Name ExportedCommands


Manifest 1.0.0.0 AppBackgroundTask {Disable-AppBackgroundTaskDiagnosticLog, Enable-AppBackgroundTaskDiagnosticLog, Set-AppBackgroundTaskResourcePolicy, Unregister-Ap...
Manifest 2.0.0.0 AppLocker {Get-AppLockerFileInformation, Get-AppLockerPolicy, New-AppLockerPolicy, Set-AppLockerPolicy...}
Manifest 1.0.0.0 AppvClient {Add-AppvClientConnectionGroup, Add-AppvClientPackage, Add-AppvPublishingServer, Disable-Appv...}
Manifest 2.0.1.0 Appx {Add-AppxPackage, Get-AppxPackage, Get-AppxPackageManifest, Remove-AppxPackage...}
Script 1.0.0.0 AssignedAccess {Clear-AssignedAccess, Get-AssignedAccess, Set-AssignedAccess}
Manifest 1.0.0.0 BitLocker {Unlock-BitLocker, Suspend-BitLocker, Resume-BitLocker, Remove-BitLockerKeyProtector...}
Manifest 2.0.0.0 BitsTransfer {Add-BitsFile, Complete-BitsTransfer, Get-BitsTransfer, Remove-BitsTransfer...}
Manifest 1.0.0.0 BranchCache {Add-BCDataCacheExtension, Clear-BCCache, Disable-BC, Disable-BCDowngrading...}
Manifest 1.0.0.0 CimCmdlets {Get-CimAssociatedInstance, Get-CimClass, Get-CimInstance, Get-CimSession...}
Manifest 1.0 ConfigCI {Get-SystemDriver, New-CIPolicyRule, New-CIPolicy, Get-CIPolicy...}
Manifest 1.0 ConfigDefender {Get-MpPreference, Set-MpPreference, Add-MpPreference, Remove-MpPreference...}
Manifest 1.0 Defender {Get-MpPreference, Set-MpPreference, Add-MpPreference, Remove-MpPreference...}
Manifest 1.0.2.0 DeliveryOptimization {Delete-DeliveryOptimizationCache, Get-DeliveryOptimizationStatus, Set-DeliveryOptimizationStatus, Get-DeliveryOptimizationPerfSna...
Manifest 1.0.0.0 DirectAccessClientComponents {Disable-DAManualEntryPointSelection, Enable-DAManualEntryPointSelection, Get-DAClientExperienceConfiguration, Get-DAEntryPointTab...
Script 3.0 Dism {Add-AppxProvisionedPackage, Add-WindowsDriver, Add-WindowsCapability, Add-WindowsImage...}
Manifest 1.0.0.0 DnsClient {Resolve-DnsName, Clear-DnsClientCache, Get-DnsClient, Get-DnsClientCache...}
Manifest 1.0.0.0 EventTracingManagement {Start-EtwTraceSession, New-EtwTraceSession, Get-EtwTraceSession, Update-EtwTraceSession...}
Manifest 1.0.0.0 HgsClient {Get-HgsAttestationBaselinePolicy, Get-HgsClientConfiguration, Test-HgsClientConfiguration, Set-HgsClientConfiguration...}
Manifest 1.0.0.0 HgsDiagnostics {New-HgsTraceTarget, Get-HgsTrace, Get-HgsTraceFileData, Test-HgsTraceTarget}
Manifest 1.0.0.1 HostNetworkingService {Remove-HnsNamespace, Remove-HnsEndpoint, Get-HnsEndpoint, Get-HnsNamespace...}
Binary 2.0.0.0 Hyper-V {Add-VMAssignableDevice, Add-VMDvdDrive, Add-VMFibreChannelHba, Add-VMGpuPartitionAdapter...}
Binary 1.1 Hyper-V {Add-VMDvdDrive, Add-VMFibreChannelHba, Add-VMHardDiskDrive, Add-VMMigrationNetwork...}
Manifest 2.0.0.0 International {Get-WinDefaultInputMethodOverride, Set-WinDefaultInputMethodOverride, Get-WinHomeLocation, Set-WinHomeLocation...}
Manifest 1.0.0.0 iSCSI {Get-IscsiTargetPortal, New-IscsiTargetPortal, Remove-IscsiTargetPortal, Update-IscsiTargetPortal...}
Script 1.0.0.0 ISE {New-IseSnippet, Import-IseSnippet, Get-IseSnippet}
Manifest 1.0.0.0 Kds {Add-KdsRootKey, Get-KdsRootKey, Test-KdsRootKey, Set-KdsConfiguration...}
Manifest 1.0.1.0 Microsoft.PowerShell.Archive {Compress-Archive, Expand-Archive}
Manifest 3.0.0.0 Microsoft.PowerShell.Diagnostics {Get-WinEvent, Get-Counter, Import-Counter, Export-Counter...}
Manifest 3.0.0.0 Microsoft.PowerShell.Host {Start-Transcript, Stop-Transcript}
Manifest 1.0.0.0 Microsoft.PowerShell.LocalAccounts {Add-LocalGroupMember, Disable-LocalUser, Enable-LocalUser, Get-LocalGroup...}
Manifest 3.1.0.0 Microsoft.PowerShell.Management {Add-Content, Clear-Content, Clear-ItemProperty, Join-Path...}
Script 1.0 Microsoft.PowerShell.ODataUtils Export-ODataEndpointProxy
Manifest 3.0.0.0 Microsoft.PowerShell.Security {Get-Acl, Set-Acl, Get-PfxCertificate, Get-Credential...}
Manifest 3.1.0.0 Microsoft.PowerShell.Utility {Format-List, Format-Custom, Format-Table, Format-Wide...}
Manifest 3.0.0.0 Microsoft.WSMan.Management {Disable-WSManCredSSP, Enable-WSManCredSSP, Get-WSManCredSSP, Set-WSManQuickConfig...}
Manifest 1.0 MMAgent {Disable-MMAgent, Enable-MMAgent, Set-MMAgent, Get-MMAgent...}
Manifest 1.0.0.0 MsDtc {New-DtcDiagnosticTransaction, Complete-DtcDiagnosticTransaction, Join-DtcDiagnosticResourceManager, Receive-DtcDiagnosticTransact...
Manifest 2.0.0.0 NetAdapter {Disable-NetAdapter, Disable-NetAdapterBinding, Disable-NetAdapterChecksumOffload, Disable-NetAdapterEncapsulatedPacketTaskOffload...
Manifest 1.0.0.0 NetConnection {Get-NetConnectionProfile, Set-NetConnectionProfile}
Manifest 1.0.0.0 NetDiagnostics Get-NetView
Manifest 1.0.0.0 NetEventPacketCapture {New-NetEventSession, Remove-NetEventSession, Get-NetEventSession, Set-NetEventSession...}
Manifest 2.0.0.0 NetLbfo {Add-NetLbfoTeamMember, Add-NetLbfoTeamNic, Get-NetLbfoTeam, Get-NetLbfoTeamMember...}
Manifest 1.0.0.0 NetNat {Get-NetNat, Get-NetNatExternalAddress, Get-NetNatStaticMapping, Get-NetNatSession...}
Manifest 2.0.0.0 NetQos {Get-NetQosPolicy, Set-NetQosPolicy, Remove-NetQosPolicy, New-NetQosPolicy}
Manifest 2.0.0.0 NetSecurity {Get-DAPolicyChange, New-NetIPsecAuthProposal, New-NetIPsecMainModeCryptoProposal, New-NetIPsecQuickModeCryptoProposal...}
Manifest 1.0.0.0 NetSwitchTeam {New-NetSwitchTeam, Remove-NetSwitchTeam, Get-NetSwitchTeam, Rename-NetSwitchTeam...}
Manifest 1.0.0.0 NetTCPIP {Get-NetIPAddress, Get-NetIPInterface, Get-NetIPv4Protocol, Get-NetIPv6Protocol...}
Manifest 1.0.0.0 NetworkConnectivityStatus {Get-DAConnectionStatus, Get-NCSIPolicyConfiguration, Reset-NCSIPolicyConfiguration, Set-NCSIPolicyConfiguration}
Manifest 1.0.0.0 NetworkSwitchManager {Disable-NetworkSwitchEthernetPort, Enable-NetworkSwitchEthernetPort, Get-NetworkSwitchEthernetPort, Remove-NetworkSwitchEthernetP...
Manifest 1.0.0.0 NetworkTransition {Add-NetIPHttpsCertBinding, Disable-NetDnsTransitionConfiguration, Disable-NetIPHttpsProfile, Disable-NetNatTransitionConfiguratio...
Manifest 1.0.0.0 PcsvDevice {Get-PcsvDevice, Start-PcsvDevice, Stop-PcsvDevice, Restart-PcsvDevice...}
Binary 1.0.0.0 PersistentMemory {Get-PmemDisk, Get-PmemPhysicalDevice, Get-PmemUnusedRegion, New-PmemDisk...}
Manifest 1.0.0.0 PKI {Add-CertificateEnrollmentPolicyServer, Export-Certificate, Export-PfxCertificate, Get-CertificateAutoEnrollmentPolicy...}
Manifest 1.0.0.0 PnpDevice {Get-PnpDevice, Get-PnpDeviceProperty, Enable-PnpDevice, Disable-PnpDevice}
Manifest 1.1 PrintManagement {Add-Printer, Add-PrinterDriver, Add-PrinterPort, Get-PrintConfiguration...}
Binary 1.0.11 ProcessMitigations {Get-ProcessMitigation, Set-ProcessMitigation, ConvertTo-ProcessMitigationPolicy}
Script 3.0 Provisioning {Install-ProvisioningPackage, Export-ProvisioningPackage, Install-TrustedProvisioningCertificate, Export-Trace...}
Manifest 1.1 PSDesiredStateConfiguration {Set-DscLocalConfigurationManager, Start-DscConfiguration, Test-DscConfiguration, Publish-DscConfiguration...}
Script 1.0.0.0 PSDiagnostics {Disable-PSTrace, Disable-PSWSManCombinedTrace, Disable-WSManTrace, Enable-PSTrace...}
Binary 1.1.0.0 PSScheduledJob {New-JobTrigger, Add-JobTrigger, Remove-JobTrigger, Get-JobTrigger...}
Manifest 2.0.0.0 PSWorkflow {New-PSWorkflowExecutionOption, New-PSWorkflowSession, nwsn}
Manifest 1.0.0.0 PSWorkflowUtility Invoke-AsWorkflow
Manifest 1.0.0.0 ScheduledTasks {Get-ScheduledTask, Set-ScheduledTask, Register-ScheduledTask, Unregister-ScheduledTask...}
Manifest 2.0.0.0 SecureBoot {Confirm-SecureBootUEFI, Set-SecureBootUEFI, Get-SecureBootUEFI, Format-SecureBootUEFI...}
Manifest 2.0.0.0 SmbShare {Get-SmbShare, Remove-SmbShare, Set-SmbShare, Block-SmbShareAccess...}
Manifest 2.0.0.0 SmbWitness {Get-SmbWitnessClient, Move-SmbWitnessClient, gsmbw, msmbw...}
Manifest 1.0.0.0 StartLayout {Export-StartLayout, Import-StartLayout, Export-StartLayoutEdgeAssets, Get-StartApps}
Manifest 2.0.0.0 Storage {Add-InitiatorIdToMaskingSet, Add-PartitionAccessPath, Add-PhysicalDisk, Add-StorageFaultDomain...}
Manifest 1.0.0.0 StorageBusCache {Clear-StorageBusDisk, Disable-StorageBusCache, Disable-StorageBusDisk, Enable-StorageBusCache...}
Manifest 2.0.0.0 TLS {New-TlsSessionTicketKey, Enable-TlsSessionTicketKey, Disable-TlsSessionTicketKey, Export-TlsSessionTicketKey...}
Manifest 1.0.0.0 TroubleshootingPack {Get-TroubleshootingPack, Invoke-TroubleshootingPack}
Manifest 2.0.0.0 TrustedPlatformModule {Get-Tpm, Initialize-Tpm, Clear-Tpm, Unblock-Tpm...}
Binary 2.1.639.0 UEV {Clear-UevConfiguration, Clear-UevAppxPackage, Restore-UevBackup, Set-UevTemplateProfile...}
Manifest 2.0.0.0 VpnClient {Add-VpnConnection, Set-VpnConnection, Remove-VpnConnection, Get-VpnConnection...}
Manifest 1.0.0.0 Wdac {Get-OdbcDriver, Set-OdbcDriver, Get-OdbcDsn, Add-OdbcDsn...}
Manifest 2.0.0.0 Whea {Get-WheaMemoryPolicy, Set-WheaMemoryPolicy}
Manifest 1.0.0.0 WindowsDeveloperLicense {Get-WindowsDeveloperLicense, Unregister-WindowsDeveloperLicense, Show-WindowsDeveloperLicenseRegistration}
Script 1.0 WindowsErrorReporting {Enable-WindowsErrorReporting, Disable-WindowsErrorReporting, Get-WindowsErrorReporting}
Manifest 1.0.0.0 WindowsSearch {Get-WindowsSearchSetting, Set-WindowsSearchSetting}
Manifest 1.0.0.0 WindowsUpdate Get-WindowsUpdateLog
Manifest 1.0.0.2 WindowsUpdateProvider {Get-WUAVersion, Get-WULastInstallationDate, Get-WULastScanSuccessDate, Get-WUIsPendingReboot...}

ディレクトリ: C:\Program Files (x86)\Microsoft Azure Information Protection\Powershell

ModuleType Version Name ExportedCommands


Binary 1.48.204.0 AzureInformationProtection {Clear-RMSAuthentication, Get-RMSFileStatus, Get-RMSServer, Get-RMSServerAuthentication...}

ディレクトリ: C:\Program Files\Microsoft Message Analyzer\PowerShell

ModuleType Version Name ExportedCommands


Script 1.1.0.0 PEF

Debug output

PS C:\Users\koyasuda> New-AzVmss -ResourceGroupName $rgname -Name $scaleSetName -VirtualMachineScaleSet $vmssConfig -Debug
デバッグ: 15:28:41 - NewAzureRmVmss begin processing with ParameterSet 'DefaultParameter'.
デバッグ: 15:28:42 - using account id '[email protected]'...
デバッグ: [Common.Authentication]: Authenticating using Account: '[email protected]', environment: 'AzureCloud', tenant: '72f988bf-86f1-41af-91ab-2d7cd011db47'
デバッグ: [Common.Authentication]: Authenticating using configuration values: Domain: '72f988bf-86f1-41af-91ab-2d7cd011db47', Endpoint: 'https://login.microsoftonline.com/', ClientId: '1950a258-22
7b-4e31-a9cf-717495945fc2', ClientRedirect: 'urn:ietf:wg:oauth:2.0:oob', ResourceClientUri: 'https://management.core.windows.net/', ValidateAuthority: 'True'
デバッグ: [Common.Authentication]: Acquiring token using context with Authority 'https://login.microsoftonline.com/72f988bf-86f1-41af-91ab-2d7cd011db47/', CorrelationId: '00000000-0000-0000-0000-0
00000000000', ValidateAuthority: 'True'
デバッグ: [Common.Authentication]: Acquiring token using AdalConfiguration with Domain: '72f988bf-86f1-41af-91ab-2d7cd011db47', AdEndpoint: 'https://login.microsoftonline.com/', ClientId: '1950a25
8-227b-4e31-a9cf-717495945fc2', ClientRedirectUri: urn:ietf:wg:oauth:2.0:oob
デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7699887Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: ADAL PCL.Desktop with assembly version '3.19.2.6005', file version '3.19.50302.01
30' and informational version '2a8bec6c4c76d0c1ef819b55bdc3cda2d2605056' is running...

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7699887Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: ADAL PCL.Desktop with assembly version '3.19.2.6005', file version '3.19.50302.01
30' and informational version '2a8bec6c4c76d0c1ef819b55bdc3cda2d2605056' is running...

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7699887Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: === Token Acquisition started:
CacheType: null
Authentication Target: User
, Authority Host: login.microsoftonline.com

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7699887Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: === Token Acquisition started:
Authority: https://login.microsoftonline.com/72f988bf-86f1-41af-91ab-2d7cd011db47/
Resource: https://management.core.windows.net/
ClientId: 1950a258-227b-4e31-a9cf-717495945fc2
CacheType: null
Authentication Target: User

デバッグ: [ADAL]: Verbose: 2020-03-06T06:28:43.7709889Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: Loading from cache.

デバッグ: [ADAL]: Verbose: 2020-03-06T06:28:43.7709889Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: Loading from cache.

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: 00000000-0000-0000-0000-000000000000 - LoggerBase.cs: Deserialized 9 items to token cache.

デバッグ: [ADAL]: Verbose: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: Looking up cache for a token...

デバッグ: [ADAL]: Verbose: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: Looking up cache for a token...

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: An item matching the requested resource was found in the cache

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: An item matching the requested resource was found in the cache

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: 30.374633475 minutes left until token in cache expires

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: 30.374633475 minutes left until token in cache expires

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: A matching item (access token or refresh token or both) was found in the cache

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: A matching item (access token or refresh token or both) was found in the cache

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: === Token Acquisition finished successfully. An access token was returned: Expira
tion Time: 2020/03/06 6:59:06 +00:00

デバッグ: [ADAL]: Information: 2020-03-06T06:28:43.7879915Z: bb3f137b-a90f-4123-bd92-e68ac323e69b - LoggerBase.cs: === Token Acquisition finished successfully. An access token was returned: Expira
tion Time: 2020/03/06 6:59:06 +00:00Access Token Hash: xN5sWUNlFJ8Lh2a/vL9AFQQNkQb2kV2mhuU7rZ76G/k=
User id: 02261c1a-a7c9-45e8-a9b1-f4566190575b

デバッグ: [Common.Authentication]: Renewing Token with Type: 'Bearer', Expiry: '03/06/2020 06:59:06 +00:00', MultipleResource? 'True', Tenant: '72f988bf-86f1-41af-91ab-2d7cd011db47', UserId: 'koya
[email protected]'
デバッグ: [Common.Authentication]: User info for token DisplayId: '[email protected]', Name: Koya Yasuda, IdProvider: 'https://sts.windows.net/72f988bf-86f1-41af-91ab-2d7cd011db47/', Uid: '02
261c1a-a7c9-45e8-a9b1-f4566190575b'
デバッグ: [Common.Authentication]: Checking token expiration, token expires '03/06/2020 06:59:06 +00:00' Comparing to '03/06/2020 06:28:43 +00:00' With threshold '00:05:00', calculated time until
token expiry: '00:30:22.4514971'
デバッグ: ============================ HTTP REQUEST ============================

HTTP Method:
PUT

Absolute Uri:
https://management.azure.com/subscriptions/8aa22af4-9dad-44a9-8659-0a6884482967/resourceGroups/TestAppGW/providers/Microsoft.Compute/virtualMachineScaleSets/testuser?api-version=2019-07-01

Headers:
x-ms-client-request-id : a2692051-5d59-4813-9d69-f1af757e554e
accept-language : en-US

Body:
{
"sku": {
"name": "Standard_DS2_v2",
"capacity": 2
},
"properties": {
"upgradePolicy": {
"mode": "Automatic",
"automaticOSUpgradePolicy": {
"enableAutomaticOSUpgrade": false
}
},
"automaticRepairsPolicy": {
"enabled": false
},
"virtualMachineProfile": {
"osProfile": {
"computerNamePrefix": "testuser",
"adminUsername": "testuser",
"adminPassword": "AzureUser123"
},
"storageProfile": {
"imageReference": {
"id": "/subscriptions/8aa22af4-9dad-44a9-8659-0a6884482967/resourceGroups/0725/providers/Microsoft.Compute/images/image-image-20200210164408"
},
"osDisk": {
"writeAcceleratorEnabled": false,
"createOption": "FromImage"
}
},
"networkProfile": {
"networkInterfaceConfigurations": [
{
"name": "NetConfig",
"properties": {
"primary": true,
"enableAcceleratedNetworking": false,
"enableIPForwarding": false
}
}
]
}
}
},
"zones": [
"1",
"2",
"3"
],
"location": "japaneast",
"tags": {}
}

デバッグ: ============================ HTTP RESPONSE ============================

Status Code:
BadRequest

Headers:
Pragma : no-cache
x-ms-ratelimit-remaining-resource: Microsoft.Compute/CreateVMScaleSet3Min;59,Microsoft.Compute/CreateVMScaleSet30Min;299
Strict-Transport-Security : max-age=31536000; includeSubDomains
x-ms-request-id : 293aee18-4ac1-4d36-982a-c174a30234da
Cache-Control : no-cache
Server : Microsoft-HTTPAPI/2.0,Microsoft-HTTPAPI/2.0
x-ms-ratelimit-remaining-subscription-writes: 1199
x-ms-correlation-request-id : 874e72df-1662-4102-afa1-97e755a006cd
x-ms-routing-request-id : EASTASIA:20200306T062847Z:874e72df-1662-4102-afa1-97e755a006cd
X-Content-Type-Options : nosniff
Date : Fri, 06 Mar 2020 06:28:46 GMT

Body:
{
"error": {
"code": "BadRequest",
"message": "Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled."
}
}

デバッグ: AzureQoSEvent: CommandName - New-AzVmss; IsSuccess - True; Duration - 00:00:06.5790828;
デバッグ: Finish sending metric.
デバッグ: 15:28:48 - NewAzureRmVmss end processing.
New-AzVmss : Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorCode: BadRequest
ErrorMessage: Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorTarget:
StatusCode: 400
ReasonPhrase: Bad Request
OperationID : 293aee18-4ac1-4d36-982a-c174a30234da
発生場所 行:1 文字:1

  • New-AzVmss -ResourceGroupName $rgname -Name $scaleSetName -VirtualMac ...
  •   + CategoryInfo          : CloseError: (:) [New-AzVmss]、ComputeCloudException
      + FullyQualifiedErrorId : Microsoft.Azure.Commands.Compute.Automation.NewAzureRmVmss
    
    

デバッグ: AzureQoSEvent: CommandName - New-AzVmss; IsSuccess - False; Duration - 00:00:06.5790828;; Exception - Microsoft.Azure.Commands.Compute.Common.ComputeCloudException: Automatic repairs fea
ture on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorCode: BadRequest
ErrorMessage: Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorTarget:
StatusCode: 400
ReasonPhrase: Bad Request
OperationID : 293aee18-4ac1-4d36-982a-c174a30234da ---> Microsoft.Rest.Azure.CloudException: Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is en
abled.
場所 Microsoft.Azure.Management.Compute.VirtualMachineScaleSetsOperations.d__26.MoveNext()
--- 直前に例外がスローされた場所からのスタック トレースの終わり ---
場所 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
場所 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
場所 System.Runtime.CompilerServices.ConfiguredTaskAwaitable1.ConfiguredTaskAwaiter.GetResult() 場所 Microsoft.Azure.Management.Compute.VirtualMachineScaleSetsOperations.<CreateOrUpdateWithHttpMessagesAsync>d__5.MoveNext() --- 直前に例外がスローされた場所からのスタック トレースの終わり --- 場所 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() 場所 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) 場所 System.Runtime.CompilerServices.ConfiguredTaskAwaitable1.ConfiguredTaskAwaiter.GetResult()
場所 Microsoft.Azure.Management.Compute.VirtualMachineScaleSetsOperationsExtensions.d__1.MoveNext()
--- 直前に例外がスローされた場所からのスタック トレースの終わり ---
場所 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
場所 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
場所 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
場所 Microsoft.Azure.Management.Compute.VirtualMachineScaleSetsOperationsExtensions.CreateOrUpdate(IVirtualMachineScaleSetsOperations operations, String resourceGroupName, String vmScaleSetNa
me, VirtualMachineScaleSet parameters)
場所 Microsoft.Azure.Commands.Compute.Automation.NewAzureRmVmss.b__1_0()
場所 Microsoft.Azure.Commands.Compute.ComputeClientBaseCmdlet.ExecuteClientAction(Action action)
--- 内部例外スタック トレースの終わり ---
場所 Microsoft.Azure.Commands.Compute.ComputeClientBaseCmdlet.ExecuteClientAction(Action action)
場所 Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.ProcessRecord();
デバッグ: Finish sending metric.
デバッグ: 15:28:51 - NewAzureRmVmss end processing.

PS C:\Users\koyasuda>

Error output

PS C:\Users\koyasuda> Resolve-AzError
警告: Breaking changes in the cmdlet 'Resolve-AzError' :
警告: - The Resolve-Error alias will be removed in a future release. Please change any scripts that use this alias to use Resolve-AzError instead.

警告: NOTE : Go to https://aka.ms/azps-changewarnings for steps to suppress this breaking change warning, and other information on breaking changes in Azure PowerShell.

HistoryId: 5

RequestId :
Message : Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorCode: BadRequest
ErrorMessage: Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorTarget:
StatusCode: 400
ReasonPhrase: Bad Request
OperationID : 293aee18-4ac1-4d36-982a-c174a30234da
ServerMessage :
ServerResponse :
RequestMessage :
InvocationInfo : {New-AzVmss}
Line : New-AzVmss -ResourceGroupName $rgname -Name $scaleSetName -VirtualMachineScaleSet $vmssConfig -Debug
Position : 発生場所 行:1 文字:1
+ New-AzVmss -ResourceGroupName $rgname -Name $scaleSetName -VirtualMac ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
StackTrace : 場所 Microsoft.Azure.Commands.Compute.ComputeClientBaseCmdlet.ExecuteClientAction(Action action)
場所 Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.ProcessRecord()
HistoryId : 5

HistoryId: 2

RequestId :
Message : Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorCode: BadRequest
ErrorMessage: Automatic repairs feature on Virtual Machine Scale Set is supported when singlePlacementGroup is enabled.
ErrorTarget:
StatusCode: 400
ReasonPhrase: Bad Request
OperationID : 6f46d687-7ce4-45d4-8e51-62316780cb4b
ServerMessage :
ServerResponse :
RequestMessage :
InvocationInfo : {New-AzVmss}
Line : New-AzVmss `

Position : 発生場所 行:24 文字:1
+ New-AzVmss `
+ ~~~~~~~~~~~~
StackTrace : 場所 Microsoft.Azure.Commands.Compute.ComputeClientBaseCmdlet.ExecuteClientAction(Action action)
場所 Microsoft.WindowsAzure.Commands.Utilities.Common.AzurePSCmdlet.ProcessRecord()
HistoryId : 2

@dingmeng-xue dingmeng-xue added Compute - VMSS customer-reported Service Attention This issue is responsible by Azure service team. and removed triage labels Mar 6, 2020
@ghost
Copy link

ghost commented Mar 6, 2020

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @mjconnection, @Drewm3, @avirishuv

@dingmeng-xue
Copy link
Member

New-AzVmss belongs to Az.Compute module. If you can share version of it, it will be helpful.

@avirishuv
Copy link

adding @rareddaz

@koyasuda-msft : looking into this, will provide an update.

@hyonholee
Copy link
Contributor

We are investigating the issue. SinglePlacementGroup should be true by default, but in this case, this is not.

To mitigate the issue now, please add '$vmssConfig.AutomaticRepairsPolicy = $null' before New-AzVmss.

$vmssConfig.AutomaticRepairsPolicy = $null
New-AzVmss -ResourceGroupName $rgname -Name $scaleSetName -VirtualMachineScaleSet $vmssConfig -Debug

@Drewm3
Copy link
Member

Drewm3 commented Mar 7, 2020

The enable automatic repairs functionality is a preview feature that is moving from limited preview to broad preview . We have not blogged about this yet or updated our documentation.

To use this functionality you must use a single placement group at this time. I will double check to make sure the API documentation and therefor the PS documentation covers the fact that a single placement group is required to use the automatic repair option.

@Drewm3
Copy link
Member

Drewm3 commented Mar 7, 2020

@Drewm3 Drewm3 closed this as completed Mar 7, 2020
@Drewm3
Copy link
Member

Drewm3 commented Mar 10, 2020

Opening this again. I had misunderstood the issue when I originally closed it.

@Drewm3 Drewm3 reopened this Mar 10, 2020
@koyasuda-msft
Copy link
Author

add '$vmssConfig.AutomaticRepairsPolicy = $null' before New-AzVmss.
I and Cx could avoid the error using workaround.
Can I ask 2 things?

  1. Are AutomaticRepairsPolicy and SinglePlacementGroup enabled by default in latest Az version(3.5.0) when we command New-AzVmss?

  2. Cx says this is a problem because this function is in preview let.
    Do you have any plans to change this?

@Drewm3 Drewm3 assigned Drewm3 and avirishuv and unassigned Drewm3 Mar 11, 2020
@koyasuda-msft
Copy link
Author

@Drewm3
Could you answer my question?
Cx doubt that this behavior is a product bug and ask to receive opinion.

@avirishuv
Copy link

@koyasuda-msft
The AutomaticRepairsPolicy is not enabled by default while using the New-AzVmss cmdlet.
The default value of SinglePlacementGroup is false when using the New-AzVmss cmdlet.

@Drewm3
Copy link
Member

Drewm3 commented Mar 17, 2020

The problem the customer was hitting was a product bug. The product was incorrectly looking for SinglePlacementGroup even if the AutomaticRepairsPolicy was not enabled. Basically if AutomaticRepairs was defined and false it was incorrectly treating it as defined and true in the validation for Single Placement Group. The fix for this is being deployed out now.

@koyasuda-msft
Copy link
Author

Thank you!
I will tell it for CX!

@avirishuv
Copy link

The fix has been deployed, closing the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Compute - VMSS customer-reported Service Attention This issue is responsible by Azure service team.
Projects
None yet
Development

No branches or pull requests

5 participants