vSphere PowerCLI Reference

Format-VMHostDiskPartition

Synopsis

Formats a new VMFS (Virtual Machine File System) on each of the specified host disk partitions.

Syntax

Format-VMHostDiskPartition [-VolumeName] <String> -VMHostDiskPartition <VMHostDiskPartition[]> [-WhatIf] [-Confirm] [<CommonParameters>]

Related Commands

Online version
Get-VMHostDiskPartition

Detailed Description

Formats a new VMFS (Virtual Machine File System) on each of the specified host disk partitions.

Parameters

NameTypeDescriptionRequired?Pipeline InputDefault Value
VolumeNameStringSpecify a name for the new VMFS.truefalse
ConfirmSwitchParameterIf 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.falsefalse
VMHostDiskPartitionVMHostDiskPartition[]Specify the disk partitions on which you want to format a new VMFS.truetrue (ByValue)
WhatIfSwitchParameterIndicate that the cmdlet is run only to display the changes that would be made and actually no objects are modified.falsefalse

Return Type

VMHostDiskPartition

Notes

Examples

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

Get-VMHost Host | Get-VMHostDisk | Get-VMHostDiskPartition | ? {.Type -eq "Ntfs"} | Format-VMHostDiskPartition -VolumeName "NewStorage"

Formats the NTFS disk partitions of a host.


Copyright © 1998 - 2011 VMware, Inc. All rights reserved.