Wednesday, August 26, 2009

Virtual Centos Guests

By default, a redhat/centos/fedora machine uses 1000 hz timers. This is good to maintain response to the user in a GUI, but not really needed in a headless environment. In a virtualised environment this configuration can make cpu usage on the host machine unnecessarily high, just in order to keep track of the time.

Previous getting around this problem required recompiling the kernel, but now there's an easier option. Just add divider=10 to the kernel parameters. Or if you prefer not to stress about whether or not you're putting the kernel parameters in the right conf file, just run this command as root.

grubby --update-kernel=ALL --args="divider=10"

2 comments:

  1. What OS/VM software are you using to run this?

    ReplyDelete
  2. Centos 5.3 host running virtualbox with centos 5.3 guests.

    ReplyDelete