By default, swap files for a virtual machine are on a datastore in the folder that contains the other virtual machine files. However, you can instead configure the hosts in your cluster to place virtual machine swap files on an alternative datastore of your choice.

You can configure an alternative swap file location to place virtual machine swap files on either lower-cost or higher-performance storage, depending on your needs.

Prerequisites

Before you configure a virtual machine swap file location for a cluster, you must configure the virtual machine swap file locations for the hosts in the cluster as described in Configure Virtual Machine Swapfile Properties for the Host.

Procedure

  1. Browse to the cluster in the vSphere Client.
  2. Click Configure.
  3. Select Configuration > General.
  4. Next to swap file location, click Edit.
  5. Select where to store the swap file.
    Option Description
    Virtual machine directory Stores the swap file in the same directory as the virtual machine configuration file.
    Datastore specified by host Stores the swap file in the location specified in the host configuration.

    If the swap file cannot be stored on the datastore that the host specifies, the swap file is stored in the same folder as the virtual machine.

  6. Click OK.