## PowerCLI Reference

# Remove-VDisk

## Synopsis

This cmdlet removes VDisk objects and the associated backings from the datastore.

Syntax

Remove-VDisk [-VDisk] <VDisk[]> [-WhatIf] [-Confirm] [<CommonParameters>]

Related Commands

Online version
Copy-VDisk
Get-VDisk
Move-VDisk
New-VDisk
Set-VDisk

Detailed Description

This cmdlet removes VDisk objects and the associated backings from the datastore. Removal of VDisk objects which are attached to a virtual machine is not allowed.

Parameters

Name | Type | Description | Required? | Pipeline Input | Default Value
--- | --- | --- | --- | --- | ---
VDisk | VDisk[] | Specifies the VDisk objects you want to remove. | true | true (ByValue)
Confirm | SwitchParameter | If the value is $true, indicates that the cmdlet asks for confirmation before running. If the value is $false, the cmdlet runs without asking for user confirmation. | false | false
WhatIf | SwitchParameter | Indicates that the cmdlet is run only to display the changes that would be made and actually no objects are modified. | false | false

Return Type

None

Notes

Examples

-------------- Example 1 --------------

    Remove-VDisk -VDisk $vDisk

Removes the $vDisk VDisk object from the server and datastore.

Copyright © VMware, Inc. All rights reserved.