Virtualization

Improve disk performance for Red Hat Enterprise Linux running in a VMware and xen environment.

VMware datastore In virtualization systems such as VMware or XenSource, disks are accessed through the host. Letting the host manage disk I/O for the guest OS can improve performance because the host already queues disk I/O requests and can allocate them more efficiently. We therefore change the guest’s I/O scheduler to noop, allowing the host to optimize I/O requests. For a Red Hat Enterprise Linux guest: Edit grub.conf:

title Red Hat Enterprise Linux Server (2.6.18-8.el5)
root (hd0,0)
kernel /vmlinuz-2.6.18-8.el5 ro root=/dev/vg0/lv0 elevator=noop
initrd /initrd-2.6.18-8.el5.img

Then reboot the system. After rebooting, the I/O scheduler should be set to noop:

# cat /sys/block/hda/queue/scheduler
[noop] anticipatory deadline cfq

To change it without rebooting (the setting returns to the default after a reboot), use the following method. Run echo as shown below to write noop to /sys/block/hda/queue/scheduler:

# echo 'noop' > /sys/block/hda/queue/scheduler

Check the I/O scheduler; it should now be noop:

# cat /sys/block/hda/queue/scheduler
[noop] anticipatory deadline cfq

Notes Host means the machine running VMware or Xen. Guest means the virtual machine.

EOF.← Back to articles