VMware Server Performance Tuning on Linux

There are a lot of postings out on the Net about performance tuning VMware products to run more efficiently. I'd thought I'd share some that I thought were farily useful (most related to running VMware Server on a Linux host).

The following are great resources:


Although the title of the first link says Ubuntu, most of these tweaks can be performed on a VMware Server host running almost any Linux distribution. That link also recommends setting mainMem.useNamedFile to false. I did not add that to my /etc/vmware/config file and instead set the working directory for my VMs to /dev/shm as well as the temporary directory. Do this by adding the following line to your VMs vmx file:

workingDir = "/dev/shm"

This makes the .vmem file get "written" to /dev/shm which is actually system RAM. In effect you are really giving real system RAM to the VM.

I also made sure that my tmpfs mounted at /dev/shm is at least 3GB (I have a workstation with 4GB of RAM) by modifying the tmpfs line in /etc/fstab as follows:

tmpfs /dev/shm tmpfs size=3G,nr_inodes=5k,mode=777 0 0

Careful, the 777 mode allows anyone to write to /dev/shm. You may want to create a security group for those people allowed to start VMs and change the mode to 770.

With those tweaks, my Vista VM is actually now usable.

Some caveats - these tweaks should only be made to hosts that have a decent amount of physical RAM. Also, make sure that the total RAM of all of your VMs that use the workingDir does not exceed the size of the tmpfs you've created.

Happy VMing.