Virtualbox and the Linux Tickless Timer

There is currently an issue with Virtualbox and linux guests that have their kernel compiled with tickless timer support (CONFIG_NO_HZ) enabled.  What happens is that when the linux guest is idle, the CPU on the host gets pegged at 100%, or close to it.  SUN is currently investigating this issue, so they recommend that if you are having an issue, then either re-compile your linux kernel to disable the tickless timer support, or add the following to the boot parameters in your grub.conf file, and reboot.

nohz=off

If the problem isn’t fixed by that option, the other thing to try is to see if running the following command resolves the problem:

modprobe vboxdrv force_async_tsc=1

If that works, you can put that in the init script for the vbox driver.  To do that, edit /etc/init.d/vboxdrv with your favorite editor.

edit the following line:

if ! modprobe $MODNAME > /dev/null 2>&1; then

so that it says this:

if ! modprobe $MODNAME force_async_tsc=1 > /dev/null 2>&1; then

This second item may not need to be done, but it has helped people in the past, if the first option doesn’t work.  Hopefully SUN will have a workaround for this in the near future.

No Comments »

on November 21st 2008 in Linux, Virtualbox

Trackback URI | Comments RSS

Leave a Reply