Thursday, April 3, 2008

Some other useful VMWare tips

Since Venkat posted some nice tips for VMWare, I thought I would add a couple of my own.

Pre-allocate Disk
There are significant performance increases in pre-allocating the disk. Obviously this take more space, but it can really save having a fragmented image. This can also save on having to defragment all the time.

Split Disk
When building the image, make sure to split the disk into 2 GB files.

Run VM image from separate physical drive than the host
The host drive is going to be busy enough, if you have a second drive, use it! Also if you are using a laptop, there is a very good chance that the internal drive is a 4200 or 5400 RPM drive. These are really slow and to slow to run anything other than one VM that you are going to use Notepad on.

External Drive Solutions
I have tried a couple different drives running through USB, but this really is not much better than running on the host drive. USB is too slow for this type of use. You could use firewire, but not many x86 machines have firewire. One of the newer things to come out is eSATA (http://en.wikipedia.org/wiki/Serial_ATA#eSATA_in_comparison_to_other_external_buses). I purchased a 7200 RPM 2.5" drive with an eSATA enclosure and eSATA PCMCIA card for about $250.00. This will work without an external power supply, which is great

Here are the parts
- SEAGATE 160GB Momentus 7200.2 SATA Notebook HDD w/ G-Force Protection, NCQ, 8MB Cache
- Vantec eSATA 2-Port SATA PCMCIA Adapter (there is also an express card version)
- Vantec Nexstar 3 eSATA Aluminum 3.5" Enclosure, eSATA & USB2.0

This drive gets about 55Mb/s transfer versus my internal 5400 RPM drive at about 25Mb/s.

Image Snapshots
Snapshots are supposed to only cause a very minor amount of performance impact on the VM image, but if you don't need the snapshot, get rid of it.

Disk Space
Make sure there is more than 30% disk space available on the physical disk. There are many write ups on this topic that state when you drop below 30% free, there is significant slow down in performance.

Defrag
Make sure that there is a regular defrag of the physical drive along with defragmenting the VM drive.

A couple links for your viewing pleasure
http://www.virtualization.info/2005/11/how-to-improve-disk-io-performances.html

http://www.scribd.com/doc/281249/Vmware-server-tips-tricks-vmworld-2006

Hope this helps.

Martin

No comments: