«

»

Feb 07 2011

Save [VDI] Storage using VM Swap File Host Placement

When designing VDI solutions for VMware infrastructures, one of the many ways to reduce shared storage consumption is to allow the placement of VM Swap files (.vswp) on host local storage. The .vswp file is automatically created by ESX when the VM is Powered On, and automatically removed when the VM is Powered Off.

(if you read the article in full you will find a little surprise at the end)

The size of the .vswp file is equal to the memory size allocated to the VM, minus any memory reservation assigned to the VM. As an example, assume a virtual desktop with Windows 7 has 2GB RAM and 1GB memory reservation. In this case the .vswp file is 1GB.

In a deployment with 1000 virtual desktop with 2GB RAM and without any memory reservation would be possible to save approximately 3TB of SAN storage when allowing the placement of .vswp on local storage. Using the same numbers, would be required approximately 192GB of local storage to host VM swap files in each host. (bear in mind I am making some assumptions to show you these numbers).

The main benefits of offloading the VM Swap files to local storage are:

  • Reduction of the shared storage datastores based on number of desktops per datastore, memory allocated to a VM and its reservation.
  • Reduction of read/write I/O from shared storage, reducing overall I/O profile.

There are also downsides that should be observed when allowing VM Swap file placement to local storage:

  • Slight impact on performance of vMotion and HA operations.
  • Slight increased CPU and memory requirement on the ESX host to handle the I/O for local .vswp files.
  • Increased local storage requirement on ESX hosts based on number of desktops per datastore, memory allocated to a VM and its reservation.

When moving .vswp to local storage it is recommended to provide local storage capable of providing large number of IOPS and throughput. SSDs are ideal, however many solutions are still using 15K drives without major problems. However, I recommend you to pay attention to those two metrics just make sure users are getting the best possible performance.

In no particular order, the most common techniques utilised to reduce storage consumption from a host and application perspective are (does not include storage array techniques such as LUN Thin Provisioning, Deduplication, etc..):

 

image

 

Configuring for Local VM Swap

There are two simple steps to follow in order to configure your ESX cluster to support local host .vswp files. The first step is to configure the HA cluster to “Store the swapfile in the datastore specified by the host”.

image

The second step need to be completed for each host member of the cluster. Under Configuration, select Virtual Machine Swapfile Location and then select the local datastore to be used to host the .vswp files.

image

Now your cluster and hosts are ready to start using local storage for .vswp files. Existing VMs will need to be restarted to have their .vswp created on local storage.

 

VDI Calculator

Ok, the surprise is that I have added local storage calculation to my VDI Calculator. When selecting “Place VM .vswp on Local Storage” the calculator will deduct the total .vswp  from share storage utilisation and provide the amount of local disk required to support the virtual desktops.

 

image image

To access the VDI Calculator check here or select VDI Calculator from the Top Menu.

Similar Posts:

Permanent link to this article: http://myvirtualcloud.net/?p=1654

3 pings

  1. Tweets that mention myvirtualcloud.net » Save [VDI] Storage using VM Swap File Host Placement -- Topsy.com

    [...] This post was mentioned on Twitter by StarWind Software, Arjan Timmerman and Walt Howd , Andre Leibovici. Andre Leibovici said: My latest article: "Save [VDI] Storage using VM Swap File Host Placement" http://bit.ly/gNLbyH #vdi #VMwareView #VMware [...]

  2. Save [VDI] Storage using VM Swap File Host Placement- Sunny with Clouds

    [...] Check the full article on myvirtualcloud.net [...]

  3. A Brief History of Desktop Storage Architecture » myvirtualcloud.net

    [...] Basic tiered storage involved moving seldom used, temporary, and non-essential desktop VM data off of “expensive” shared storage and onto host DASD. Many administrators continue to do this today. Refer to Save [VDI] Storage using VM Swap File Host Placement. [...]

Leave a Reply