Skip to content

Latest commit

 

History

History
158 lines (118 loc) · 4.05 KB

Set-AzureRmVMBootDiagnostics.md

File metadata and controls

158 lines (118 loc) · 4.05 KB
external help file Module Name ms.assetid online version schema
Microsoft.Azure.Commands.Compute.dll-Help.xml
AzureRM.Compute
9A6F140C-9F1C-4701-9603-FC6107FCAF92
2.0.0

Set-AzureRmVMBootDiagnostics

SYNOPSIS

Modifies boot diagnostics properties of a virtual machine.

SYNTAX

EnableBootDiagnostics

Set-AzureRmVMBootDiagnostics [-VM] <PSVirtualMachine> [-Enable] [-ResourceGroupName] <String>
 [[-StorageAccountName] <String>] [-DefaultProfile <IAzureContextContainer>] [<CommonParameters>]

DisableBootDiagnostics

Set-AzureRmVMBootDiagnostics [-VM] <PSVirtualMachine> [-Disable] [-DefaultProfile <IAzureContextContainer>]
 [<CommonParameters>]

DESCRIPTION

The Set-AzureRmVMBootDiagnostics cmdlet modifies boot diagnostics properties of a virtual machine.

EXAMPLES

Example 1: Enable boot diagnostics

PS C:\> $VM = Get-AzureRmVM -ResourceGroupName "ResourceGroup11" -Name "ContosoVM07"
PS C:\> Set-AzureRmVMBootDiagnostics -VM $VM -Enable -ResourceGroupName "ResourceGroup11" -StorageAccountName "DiagnosticStorage"

The first command gets the virtual machine named ContosoVM07 by using Get-AzureRmVM. The command stores it in the $VM variable. The second command enables boot diagnostics for the virtual machine in $VM. Diagnostics data is stored in the specified account.

PARAMETERS

-DefaultProfile

The credentials, account, tenant, and subscription used for communication with azure.

Type: Microsoft.Azure.Commands.Common.Authentication.Abstractions.IAzureContextContainer
Parameter Sets: (All)
Aliases: AzureRmContext, AzureCredential

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Disable

Indicates that this cmdlet disables the boot diagnostics for the virtual machine.

Type: System.Management.Automation.SwitchParameter
Parameter Sets: DisableBootDiagnostics
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-Enable

Indicates that this cmdlet enables the boot diagnostics for the virtual machine.

Type: System.Management.Automation.SwitchParameter
Parameter Sets: EnableBootDiagnostics
Aliases:

Required: True
Position: 1
Default value: None
Accept pipeline input: False
Accept wildcard characters: False

-ResourceGroupName

Specifies the name of the resource group of the virtual machine.

Type: System.String
Parameter Sets: EnableBootDiagnostics
Aliases:

Required: True
Position: 2
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-StorageAccountName

Specifies the name of the storage account in which to save boot diagnostics data.

Type: System.String
Parameter Sets: EnableBootDiagnostics
Aliases:

Required: False
Position: 3
Default value: None
Accept pipeline input: True (ByPropertyName)
Accept wildcard characters: False

-VM

Specifies the virtual machine for which this cmdlet changes boot diagnostics. To obtain a virtual machine object, use the Get-AzureRmVM cmdlet.

Type: Microsoft.Azure.Commands.Compute.Models.PSVirtualMachine
Parameter Sets: (All)
Aliases: VMProfile

Required: True
Position: 0
Default value: None
Accept pipeline input: True (ByPropertyName, ByValue)
Accept wildcard characters: False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).

INPUTS

Microsoft.Azure.Commands.Compute.Models.PSVirtualMachine

System.String

OUTPUTS

Microsoft.Azure.Commands.Compute.Models.PSVirtualMachine

NOTES

RELATED LINKS

Get-AzureRmVM

Get-AzureRmVMBootDiagnosticsData