Managing VMFS Datastores with HostStorageSystem

In most cases, the Datastore methods are appropriate for creating and managing VMFS datastores. However, in some cases the following HostStorageSystem commands are used instead:

  • AttachVmfsExtent – Extends a VMFS by attaching a disk partition as an extent.
  • ExpandVmfsExtent – Expands a VMFS extent as specified by the disk partition specification.
  • FormatVmfs – Formats a new VMFS on a disk partition based on the HostVmfsSpec that you pass in. Returns a HostVmfsVolume that represents the new VMFS file system. The HostVmfsVolume includes the block size, list of partition names of the disk’s VMFS extents, and other information including the UUID.

    This command is a low-level API you can use to partition disks explicitly. In most cases, the Datastore VMFS commands are more suitable.

  • RescanVmfs – Rescans for new VMFS instances.
  • UpgradeVmfs – Upgrades the VMFS to the current VMFS version.