Set-AzVmss
Sets specific actions on a specified VMSS.
Note
This is the previous version of our documentation. Please consult the most recent version for up-to-date information.
Syntax
Set-AzVmss
[-ResourceGroupName] <String>
[-VMScaleSetName] <String>
[[-InstanceId] <String[]>]
[-TempDisk]
[-Reimage]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-AzVmss
[-ResourceGroupName] <String>
[-VMScaleSetName] <String>
[[-InstanceId] <String[]>]
[-ReimageAll]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-AzVmss
[-ResourceGroupName] <String>
[-VMScaleSetName] <String>
[[-InstanceId] <String[]>]
[-Redeploy]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-AzVmss
[-ResourceGroupName] <String>
[-VMScaleSetName] <String>
[[-InstanceId] <String[]>]
[-PerformMaintenance]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Set-AzVmss cmdlet sets specific actions on the Virtual Machine Scale Set (VMSS). The only action this cmdlet supports is Reimage.
Examples
Example 1: Reimage a VMSS
Set-AzVmss -Reimage -ResourceGroupName "ContosoGroup" -VMScaleSetName "ContosoVMSS"
This command reimages the VMSS named ContosoVMSS that belongs to the resource group named ContosoGroup.
Example 2
Sets specific actions on a specified VMSS. (autogenerated)
Set-AzVmss -ReimageAll -ResourceGroupName 'ContosoGroup' -VMScaleSetName 'ContosoVMSS'
Parameters
Run cmdlet in the background and return a Job to track progress.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Prompts you for confirmation before running the cmdlet.
| Type: | SwitchParameter |
| Aliases: | cf |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The credentials, account, tenant, and subscription used for communication with azure.
| Type: | IAzureContextContainer |
| Aliases: | AzContext, AzureRmContext, AzureCredential |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
The instance ID of the virtual machine.
| Type: | String[] |
| Position: | 2 |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Indicates that this cmdlet performs maintenance one or more virtual machines in the VMSS.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Indicates that the cmdlet redeploys one or more virtual machines in the VMSS.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Indicates that the cmdlet reimages the VMSS.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Indicates that the cmdlet reimages all the disks in the VMSS.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Specifies the name of the resource group of the VMSS.
| Type: | String |
| Position: | 0 |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Specifies whether to reimage temp disk.
| Type: | SwitchParameter |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Species the name of the VMSS for which this cmdlet sets actions on.
| Type: | String |
| Aliases: | Name |
| Position: | 1 |
| Default value: | None |
| Accept pipeline input: | True |
| Accept wildcard characters: | False |
Shows what would happen if the cmdlet runs. The cmdlet is not run.
| Type: | SwitchParameter |
| Aliases: | wi |
| Position: | Named |
| Default value: | None |
| Accept pipeline input: | False |
| Accept wildcard characters: | False |
Inputs
String[]