< Back
Set-AzureRmVmssRollingUpgradePolicy
Post
NAME Set-AzureRmVmssRollingUpgradePolicy
SYNOPSIS
Sets the VMSS rolling upgrade policy properties.
SYNTAX
Set-AzureRmVmssRollingUpgradePolicy [-VirtualMachineScaleSet] <PSVirtualMachineScaleSet> [[-MaxBatchInstancePercent] <Int32>]
[[-MaxUnhealthyInstancePercent] <Int32>] [[-MaxUnhealthyUpgradedInstancePercent] <Int32>] [-DefaultProfile <IAzureContextContainer>]
[-PauseTimeBetweenBatches <String>] [-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
Sets the VMSS rolling upgrade policy properties.
PARAMETERS
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-MaxBatchInstancePercent <Int32>
The maximum percent of total virtual machine instances that will be upgraded simultaneously by the rolling upgrade in one batch. As this is a
maximum, unhealthy instances in previous or future batches can cause the percentage of instances in a batch to decrease to ensure higher
reliability. If the value is not specified, it is set to 20.
Required? false
Position? 1
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-MaxUnhealthyInstancePercent <Int32>
The maximum percentage of the total virtual machine instances in the scale set that can be simultaneously unhealthy, either as a result of
being upgraded, or by being found in an unhealthy state by the virtual machine health checks before the rolling upgrade aborts. This
constraint will be checked prior to starting any batch. If the value is not specified, it is set to 20.
Required? false
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-MaxUnhealthyUpgradedInstancePercent <Int32>
The maximum percentage of upgraded virtual machine instances that can be found to be in an unhealthy state. This check will happen after each
batch is upgraded. If this percentage is ever exceeded, the rolling update aborts. If the value is not specified, it is set to 20.
Required? false
Position? 3
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-PauseTimeBetweenBatches <String>
The wait time between completing the update for all virtual machines in one batch and starting the next batch. The time duration should be
specified in ISO 8601 format. The default value is 0 seconds (PT0S).
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-VirtualMachineScaleSet <PSVirtualMachineScaleSet>
Specifies the VMSS object. You can use the New-AzureRmVmssConfig cmdlet to create the object.
Required? true
Position? 0
Default value None
Accept pipeline input? True (ByPropertyName, ByValue)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
Microsoft.Azure.Commands.Compute.Automation.Models.PSVirtualMachineScaleSet
System.Nullable`1[[System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] System.String
OUTPUTS
Microsoft.Azure.Commands.Compute.Automation.Models.PSVirtualMachineScaleSet
NOTES
Example 1
PS C:\\> Set-AzureRmVmssRollingUpgradePolicy -VirtualMachineScaleSet $vmss -VirtualMachineScaleSet $vmss -MaxBatchInstancePercent 40
-MaxUnhealthyInstancePercent 35 -MaxUnhealthyUpgradedInstancePercent 30 -PauseTimeBetweenBatches "PT30S"
This command sets 40 percent for MaxBatchInstance, 35 percent for MaxUnhealthyInstance, 30 percent for MaxUnhealthyUpgradedInstance and 30 second
pause time between batches for VMSS local object $vmss.
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... radepolicy
SYNOPSIS
Sets the VMSS rolling upgrade policy properties.
SYNTAX
Set-AzureRmVmssRollingUpgradePolicy [-VirtualMachineScaleSet] <PSVirtualMachineScaleSet> [[-MaxBatchInstancePercent] <Int32>]
[[-MaxUnhealthyInstancePercent] <Int32>] [[-MaxUnhealthyUpgradedInstancePercent] <Int32>] [-DefaultProfile <IAzureContextContainer>]
[-PauseTimeBetweenBatches <String>] [-Confirm] [-WhatIf] [<CommonParameters>]
DESCRIPTION
Sets the VMSS rolling upgrade policy properties.
PARAMETERS
-DefaultProfile <IAzureContextContainer>
The credentials, account, tenant, and subscription used for communication with azure.
Required? false
Position? named
Default value None
Accept pipeline input? False
Accept wildcard characters? false
-MaxBatchInstancePercent <Int32>
The maximum percent of total virtual machine instances that will be upgraded simultaneously by the rolling upgrade in one batch. As this is a
maximum, unhealthy instances in previous or future batches can cause the percentage of instances in a batch to decrease to ensure higher
reliability. If the value is not specified, it is set to 20.
Required? false
Position? 1
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-MaxUnhealthyInstancePercent <Int32>
The maximum percentage of the total virtual machine instances in the scale set that can be simultaneously unhealthy, either as a result of
being upgraded, or by being found in an unhealthy state by the virtual machine health checks before the rolling upgrade aborts. This
constraint will be checked prior to starting any batch. If the value is not specified, it is set to 20.
Required? false
Position? 2
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-MaxUnhealthyUpgradedInstancePercent <Int32>
The maximum percentage of upgraded virtual machine instances that can be found to be in an unhealthy state. This check will happen after each
batch is upgraded. If this percentage is ever exceeded, the rolling update aborts. If the value is not specified, it is set to 20.
Required? false
Position? 3
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-PauseTimeBetweenBatches <String>
The wait time between completing the update for all virtual machines in one batch and starting the next batch. The time duration should be
specified in ISO 8601 format. The default value is 0 seconds (PT0S).
Required? false
Position? named
Default value None
Accept pipeline input? True (ByPropertyName)
Accept wildcard characters? false
-VirtualMachineScaleSet <PSVirtualMachineScaleSet>
Specifies the VMSS object. You can use the New-AzureRmVmssConfig cmdlet to create the object.
Required? true
Position? 0
Default value None
Accept pipeline input? True (ByPropertyName, ByValue)
Accept wildcard characters? false
-Confirm [<SwitchParameter>]
Prompts you for confirmation before running the cmdlet.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
-WhatIf [<SwitchParameter>]
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Required? false
Position? named
Default value False
Accept pipeline input? False
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
Microsoft.Azure.Commands.Compute.Automation.Models.PSVirtualMachineScaleSet
System.Nullable`1[[System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]] System.String
OUTPUTS
Microsoft.Azure.Commands.Compute.Automation.Models.PSVirtualMachineScaleSet
NOTES
Example 1
PS C:\\> Set-AzureRmVmssRollingUpgradePolicy -VirtualMachineScaleSet $vmss -VirtualMachineScaleSet $vmss -MaxBatchInstancePercent 40
-MaxUnhealthyInstancePercent 35 -MaxUnhealthyUpgradedInstancePercent 30 -PauseTimeBetweenBatches "PT30S"
This command sets 40 percent for MaxBatchInstance, 35 percent for MaxUnhealthyInstance, 30 percent for MaxUnhealthyUpgradedInstance and 30 second
pause time between batches for VMSS local object $vmss.
RELATED LINKS
Online Version: https://docs.microsoft.com/en-us/powers ... radepolicy