Get-AzVmssVM
Gets the properties of a VMSS virtual machine.
Get-AzVmssVM
[[-ResourceGroupName] <String>]
[[-VMScaleSetName] <String>]
[[-InstanceId] <String>]
[-UserData]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
Get-AzVmssVM
[[-ResourceGroupName] <String>]
[[-VMScaleSetName] <String>]
[[-InstanceId] <String>]
[-InstanceView]
[-UserData]
[-DefaultProfile <IAzureContextContainer>]
[<CommonParameters>]
The Get-AzVmssVM cmdlet gets the model view and instance view of a Virtual Machine Scale Set (VMSS) virtual machine. The model view is the user specified properties of the virtual machine. The instance view is the instance level status of the virtual machine. Specify the Status parameter to get only the instance view of a virtual machine.
Get-AzVmssVM -ResourceGroupName "Group001" -VMScaleSetName "VMSS001"
This command gets the properties of the VMSS virtual machine named VMSS001 that belongs to the resource group named Group001. Since the command does not specify the InstanceView switch parameter, the cmdlet gets the model view of the virtual machine.
Get-AzVmssVM -ResourceGroupName "Group002" -VMScaleSetName "VMSS004" -InstanceId $ID
This command gets the properties of the VMSS virtual machine named VMSS004 that belongs to the resource group named Group002. The command gets the instance ID stored in the variable $ID for which to get the model view.
Get-AzVmssVM -InstanceView -ResourceGroupName $rgname -VMScaleSetName $vmssName -InstanceId $ID
This command gets the properties of the VMSS virtual machine named VMSS004 that belongs to the resource group named Group002. Since the command specifies the InstanceView switch parameter, the cmdlet gets the instance view of the virtual machine. The command gets the instance ID stored in the variable $ID for which to get the instance view.
The credentials, account, tenant, and subscription used for communication with azure.
Type: | IAzureContextContainer |
Aliases: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
Specifies the instance ID for which to get the model view.
Type: | String |
Position: | 2 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Indicates that this cmdlet gets only the instance view of the virtual machine.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | True |
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 |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
UserData for the Vmss, which will be base-64 encoded. Customer should not pass any secrets in here.
Type: | SwitchParameter |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Species the name of the VMSS.
Type: | String |
Aliases: | Name |
Position: | 1 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
Azure PowerShell feedback
Azure PowerShell is an open source project. Select a link to provide feedback: