Swap File Location
By default, the swap file is created in the same location as the virtual machine's configuration file.
A swap file is created by the ESX/ESXi host when a virtual machine is powered on. If this file cannot be created,
the virtual machine cannot power on. Instead of accepting the default, you can also:
n
Use per-virtual machine configuration options to change the datastore to another shared storage location.
n
Use host-local swap, which allows you to specify a datastore stored locally on the host. This allows you
to swap at a per-host level, saving space on the SAN. However, it can lead to a slight degradation in
performance for VMware VMotion because pages swapped to a local swap file on the source host must
be transferred across the network to the destination host.
Enable Host-Local Swap for a DRS Cluster
Host-local swap allows you to specify a datastore stored locally on the host as the swap file location. You can
enable host-local swap for a DRS cluster.
Procedure
1
Right-click the cluster in the vSphere Client inventory panel and click Edit Settings.
2
In the left pane of the cluster Settings dialog box, click Swapfile Location.
3
Select the Store the swapfile in the datastore specified by the host option and click OK.
4
Select one of the cluster’s hosts in the vSphere Client inventory panel and click the Configuration tab.
5
Select Virtual Machine Swapfile Location.
6
Click the Swapfile Datastore tab.
7
From the list provided, select the local datastore to use and click OK.
8
Repeat
Step 4
through
Step 7
for each host in the cluster.
Host-local swap is now enabled for the DRS cluster.
Enable Host-Local Swap for a Standalone Host
Host-local swap allows you to specify a datastore stored locally on the host as the swap file location. You can
enable host-local swap for a standalone host.
Procedure
1
Select the host in the vSphere Client inventory panel and click the Configuration tab.
2
Select Virtual Machine Swapfile Location.
3
In the Swapfile location tab of the Virtual Machine Swapfile Location dialog box, select Store the swapfile
in the swapfile datastore.
4
Click the Swapfile Datastore tab.
5
From the list provided, select the local datastore to use and click OK.
Host-local swap is now enabled for the standalone host.
Swap Space and Memory Overcommitment
You must reserve swap space for any unreserved virtual machine memory (the difference between the
reservation and the configured memory size) on per-virtual machine swap files.
This swap reservation is required to ensure that the ESX/ESXi host is able to preserve virtual machine memory
under any circumstances. In practice, only a small fraction of the host-level swap space might be used.
Chapter 3 Managing Memory Resources
VMware, Inc.
33
Summary of Contents for ESX 4.0
Page 6: ...vSphere Resource Management Guide 6 VMware Inc...
Page 44: ...vSphere Resource Management Guide 44 VMware Inc...
Page 52: ...vSphere Resource Management Guide 52 VMware Inc...
Page 72: ...vSphere Resource Management Guide 72 VMware Inc...
Page 80: ...vSphere Resource Management Guide 80 VMware Inc...