Knowledge Base

The VMware Knowledge Base provides support solutions, error messages and troubleshooting guides
 
Search the VMware Knowledge Base (KB)   View by Article ID
 

Troubleshooting hosted disk I/O performance problems (1008885)

Symptoms

  • The virtual machine performs very slowly: applications start slowly or take a long time to appear, or the operating system takes a long time to boot.
  • Virtual machines stop responding for long periods of time.
  • Windows guests fail with STOP 0x77 KERNEL_STACK_INPAGE_ERROR, or the event log contains Event ID 51 from the source: Disk.
  • Linux guests become non-responsive or lock up.
  • The vmware.log file contains lines similar to:

    Command WRITE(10) took 10.858 seconds (ok)
    Command READ(10) took 1.173 seconds (ok)
    SCSI0: RESET BUS

Resolution

These symptoms may indicate that there is a disk performance issue on the underlying hardware. When using VMware hosted products, consider that both the virtual machines and host operating system often share the same disk resources and hardware.
 
Below are some suggestions you can implement to improve disk I/O performance issues:
 
Suggestion Details
Use non-growable or preallocated VMDK disks When creating a production virtual machine, VMware recommends that the virtual hard disk be configured to preallocated mode. If existing disks are not in preallocated mode, use the vmware-vdiskmanager tool to convert the disks. Consult the product's User Guide for more information.
Remove or reduce snapshots
When a snapshot is created, the VMware product produces an additional delta file. Each successive snapshot produces an additional file. When a disk operation is performed within the guest, the disk I/O is recreated by parsing each snapshot delta file in the chain. This produces additional disk overhead on the host because more than one file must be opened and processed to recreate the I/O data for the guest operating system. For best performance, remove all snapshots in the guest operating system or store performance-sensitive data on an independent virtual disk. Consult the product's User Guide for information on configuring independent virtual disks.
 
For more information, see Working with Snapshots (1009402).
Use separate physical and virtual hard disks Install the host operating system onto a separate hard disk from the virtual machines. Also store the paging file or swap partition on a different drive than the host operating system.
Optimize the drive Run disk defragmentation software on the host and in the guest operating system. Fragmentation of both the .vmdk files and within the guest can double the impact from fragmentation.
Use partitions Implementing partitions inside the guest operating system or host can improve performance by creating fragmentation boundaries and can reduce further fragmentation. For example, consider storing the small, often modified files of the operating system away from large files such as database or Microsoft Exchange stores by using a separate partition. Also consider storing the virtual disk files (.vmdk files) on their own partition or disk on the host
Use RAID or adjust the RAID configuration or add disks to the array Certain RAID configurations can impact read or write performance positively and negatively. When using a RAID 5 configuration, consider adding more disks to the array. This generally improves the performance of the array. Using mirroring can improve read performance but may degrade write performance. If write performance is primarily impaired, consider a different RAID type to host the virtual machine.
Check for disk encryption Disk encryption can reduce disk performance. Try moving the virtual machine to a non-encrypted volume and test if performance has improved.
Ensure the existing physical hardware is healthy and performing as expected Often disk problems such as bad sectors or failing controllers can impact performance because I/O and bad cluster auto-recovery can cause sudden interruptions in I/O operations to the device. Perform a hardware and file system diagnostic to verify if this is impacting performance. For more information, see Performing a disk check (1004003).
Upgrade or choose different physical disk hardware It is important to consider the performance characteristics of the physical disk hardware. In general, hardware RAID and independent disk controllers perform better than software RAID and integrated disk controllers. When an independent controller is used, often it is possible to configure or increase the cache memory to yield better performance. Consult the hardware vendor for more information. Typically older hardware performs slower than newer hardware. Hard disks used in laptop or notebook computers are often far slower than drives used in desktop computers. SCSI hard disks typically perform much faster than those used in regular desktops and notebooks. Hard disks connected over USB typically perform slower than directly attached local disks (such as IDE, SATA, and SCSI). Flash-based USB thumb drives typically perform slower than hard drives.

Review the performance specifications provided by the disk manufacturer on critical metrics such as spindle speed, average seek time (latency), and burst data transfer rates. Higher spindle speeds, lower seek times, and higher transfer rates perform better. When comparing flash-based drives, observe both the read and write transfer performance ratings.
Edit the virtual machine settings to reduce I/O usage by using more host memory
Adding these settings to a virtual machine can reduce the I/O load on the hard disk, however these adjustments require additional memory on the host. Only add these settings if there is sufficient free memory on the host to accommodate all the memory allocated to the virtual machine, otherwise you may cause a memory starvation condition that can reduce performance of all the running virtual machines or possibly affect the host operating system. Use these settings with caution.
 
Open the .vmx file for the affected virtual machine while it is powered off. Add the following lines to the file using a text editor. For more information, see  Editing the .vmx file of a VMware Workstation and VMware Player virtual machine (2057902)

Note
: If you are using VMware Server, you may need to restart the VMware Authorization Service (vmware-authd) for changes to take effect.

MemTrimRate = "0"
mainMem.useNamedFile = "FALSE"
sched.mem.pshare.enable = "FALSE"
prefvmx.useRecommendedLockedMemSize = "TRUE"

Note: If you are using a Linux host, use the following entry instead of mainMem.useNamedFile = "FALSE". The mainMem.useNamedFile entry only applies to Windows Hosts.

mainmem.backing = "swap"

Additional Information

For related troubleshooting information, see Troubleshooting virtual machine performance issues (1008360).

See Also

Update History

04/27/2012 - Fixed a typo

Request a Product Feature

To request a new product feature or to provide feedback on a VMware product, please visit the Request a Product Feature page.

Feedback

  • 49 Ratings

Did this article help you?
This article resolved my issue.
This article did not resolve my issue.
This article helped but additional information was required to resolve my issue.
What can we do to improve this information? (4000 or fewer characters)
  • 49 Ratings
Actions
KB: