Remove-AzureVMImageOSDiskConfig

Removes the operating system disk configuration from the DiskConfigSet object.

Note

The cmdlets referenced in this documentation are for managing legacy Azure resources that use Service Management APIs. See the Az PowerShell module for cmdlets to manage Azure Resource Manager resources.

Syntax

Remove-AzureVMImageOSDiskConfig
      [-DiskConfig] <VirtualMachineImageDiskConfigSet>
      [-InformationAction <ActionPreference>]
      [-InformationVariable <String>]
      [<CommonParameters>]

Description

The Remove-AzureVMImageOSDiskConfig cmdlet removes the operating system disk configuration from the DiskConfigSet object.

Examples

Example 1: Remove the operating system disk configuration from a DiskConfigSet

PS C:\> $Disk = New-AzureDiskConfigSet
PS C:\> $Disk = Set-AzureOSDiskConfig -DiskConfig $Disk -HostCaching ReadWrite
PS C:\> Remove-AzureVMImageOSDiskConfig -DiskConfig $Disk

This command removes the operating system disk configuration from the DiskConfigSet object

Parameters

-DiskConfig

Specifies the disk configuration object that encapsulates the operating system disk and Data Disk objects.

Type:VirtualMachineImageDiskConfigSet
Position:0
Default value:None
Required:True
Accept pipeline input:True
Accept wildcard characters:False

-InformationAction

Specifies how this cmdlet responds to an information event.

The acceptable values for this parameter are:

  • Continue
  • Ignore
  • Inquire
  • SilentlyContinue
  • Stop
  • Suspend
Type:ActionPreference
Aliases:infa
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-InformationVariable

Specifies an information variable.

Type:String
Aliases:iv
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

Outputs

Microsoft.WindowsAzure.Commands.ServiceManagement.Model.VirtualMachineImageDiskConfigSet