Contents

Previous Next

Running the VMware Virtual Disk Manager Utility
To run the VMware Virtual Disk Manager utility, open a command prompt or terminal on the GSX Server host. For Windows hosts, change to the directory where you installed your GSX Server software. By default, this directory is C:\Program Files\VMware\VMware GSX Server.
The command syntax is:
vmware-vdiskmanager [options]
The options you can or must use include:
Options/Parameters
Description
<diskname>
Is the name of the virtual disk file. The virtual disk file must have a .vmdk extension.
You can specify a path to where you want to locate the disk. If you mapped network shares on your host, you can create the virtual disk there by providing the correct path information with the disk filename.
-c
Creates the virtual disk. You must use the -a, -s and -t options, and you must specify the name of the virtual disk (<diskname>).
-r <sourcediskname> <targetdiskname>
Converts the virtual disk specified by<sourcediskname>, creating a new virtual disk as a result. You must use the -t option to specify the disk type to which the virtual disk is converted and you must specify the name of the target virtual disk (<targetdiskname>).
Once the conversion is completed and you have tested the converted virtual disk to make sure it works as expected, you can delete the original virtual disk file.
In order for the virtual machine to recognize the converted virtual disk, you should use the virtual machine settings editor to remove the existing virtual disk from the virtual machine, then add the converted disk to the virtual machine. For information on adding virtual disks to a virtual machine, see Adding Virtual Disks to a Virtual Machine.
-x <n>[GB|MB] <diskname>
Expands the virtual disk to the specified capacity. You must specify the new, larger size of the virtual disk in Gigabytes or Megabytes. You cannot change the size of a physical (raw) disk.
Caution: Before running the virtual disk manager utility, you should back up your virtual disk files.
Note: If the virtual disk is partitioned, you must use a third-party utility in the virtual machine to expand the size of the partitions. For more information, see VMware knowledge base article 1647 at www.vmware.com/support/kb/enduser/std_adp.php?p_faqid=1647.
If you have a virtual machine with a snapshot or a redo log stored in a different directory, do not use the virtual disk manager to expand the virtual disk until you remove the snapshot or commit the redo log. Otherwise, you may not be able to power on the virtual machine.
-n <sourcediskname> <targetdiskname>
Renames the virtual disk specified by <sourcediskname>. You must specify the name of the target virtual disk (<targetdiskname>). By providing directory paths, you can rename the disk and place it in a different directory or place the disk with the same name in a different directory.
Before you rename the virtual disk or change the directory in which it is located, you should remove the virtual disk from any virtual machine that contains the disk. Choose VM > Settings > <virtualdisk>, then click Remove. If this virtual machine has a snapshot or a redo log stored in a different directory, remove the snapshot or commit the redo log. Otherwise, you may not be able to power on the virtual machine.
After you rename or relocate the virtual disk, add it back to any virtual machines that use it. Choose VM > Settings, click Add, then follow the wizard to add this existing virtual disk.
-d <diskname>
Defragments the specified virtual disk. You can defragment only growable virtual disks. You cannot defragment preallocated virtual disks.
-p <mountpoint>
Prepares a virtual disk for shrinking. If the virtual disk is partitioned into volumes, each volume must be prepared separately. The volume must be mounted by VMware DiskMount at <mountpoint>. After you prepare the volume, unmount it with VMware DiskMount. Continue mounting each volume of the virtual disk and preparing it for shrinking until you complete this process for all the volumes of the virtual disk.
You can mount only one volume of a virtual disk at a time with VMware DiskMount. You can prepare volumes of virtual disks for shrinking on Windows hosts only.
-k <diskname>
Shrinks the specified virtual disk. You can shrink only growable virtual disks. You can shrink virtual disks on Windows hosts only.
You cannot shrink a virtual disk if the virtual machine has a snapshot. To keep the virtual disk in its current state, simply remove the snapshot. To discard changes made since you took the snapshot, revert to the snapshot.
-a [ide|buslogic|lsilogic]
Specifies the disk adapter type. You must specify an adapter type when creating a new virtual disk. Choose one of the following types:
  • ide — for an IDE adapter.
  • buslogic — for a BusLogic SCSI adapter.
  • lsilogic — for an LSI Logic SCSI adapter.
  • -s <n>[GB|MB]
    Specifies the size of the virtual disk. Specify whether the size <n> is in GB (Gigabytes) or MB (Megabytes). You must specify the size of a virtual disk when you create it.
    Even though you must specify the size of a virtual disk when you expand it, you do not use the -s option at that time.
    -t [0|1|2|3]
    You must specify the type of virtual disk when you create a new one or reconfigure an existing one. Specify one of the following disk types:
    0 — to create a single, growable virtual disk.
    1 — to create a growable virtual disk split into 2GB files.
    2 — to create a preallocated virtual disk contained in a single virtual disk file.
    3 — to create a preallocated virtual disk split into 2GB files.
    -q
    Disables virtual disk manager logging.
    If you keep logging enabled, messages generated by the virtual disk manager are stored in a log file. The name and location of the log file appear in the terminal after the virtual disk manager command is run.


    Previous Next