Architecting VMware vSAN 6.2 : vSAN Technology and Features Overview : 3.2 vSAN Key Features : 3.2.6 Swap Efficiency
   
3.2.6 Swap Efficiency
Virtual swap files are created when virtual machines are powered on. In cases where physical host memory is exhausted, the virtual swap file is used in place of physical memory for a virtual machine. Virtual swap files are sized according to the allocated memory minus reserved memory.
A virtual machine with 4 GB of RAM allocated and a 2-GB memory reservation will create a 2-GB virtual swap file. On vSAN, that swap file is created with a mirrored policy, resulting in 4 GB of space consumed. 100 virtual machines with the same configuration consume 400 GB of capacity. In large service provider deployments of thousands of virtual machines, this additional capacity could be substantial and require significant capacity.
In addition to the use of deduplication and compression, as well as erasure coding, it can be advantageous to use the vSAN SwapThickProvisionedDisabled advanced host setting for additional space savings.
Enabling this setting creates virtual swap files as a sparse object on the vSAN datastore. Sparse virtual swap files only consume capacity on vSAN as they are accessed. The result can be significantly less space consumed on the vSAN datastore, provided virtual machines do not experience memory over commitment, requiring use of the virtual swap file.