近日在VirtualBox上安裝了CentOS,突然發現CPU風扇狂轉,一查,原來VirtualBox上的CentOS幾乎在100%使用VirtualBox分配給它的CPU核心。 在網上找了半天,終於找到一條方法,即:修改/etc/grub.conf檔案,在kernel一行後加上參數“divider=10” ,經實驗,果然CPU正常了。
關於 divider=10 的解釋:
For RHEL 5.4 and CentOS 5.4 and later, divider=10 is a supported kernel configuration option, but is no longer necessary for accurate timekeeping. Using it reduces the frequency of timer interrupts by 10x, which reduces the CPU overhead of processing timer interrupts. This overhead is especially noticeable for idle virtual machines. The only drawback of using divider=10 is that the granularity of wakeups provided by the kernel changes from 1ms to 10ms. The vast majority of applications are not affected by this, but using divider=10 may not be the right tradeoff for some time sensitive applications. For RHEL 5.3 and earlier, divider=10 greatly improves timekeeping accuracy and is strongly recommended.