So I\'m using a couple vagrant boxes and when i have them up, \"sometimes/randomly\" it starts to take up 100% cpu on my OS X machine and i have no idea whats causing it. I
For Vagrant with CoreOS only please do the following:
$enable_serial_logging=false
in config.rb
vagrant destroy
vagrant up
This PR is a working source of this info.
For Vagrang with any vm you can also try disabling nested paging.
See "Fix High Guest CPU Utilization in VirtualBox by disabling Nested Paging" article for more info.
EngineerCoder's answer only applies if you're using CoreOS.
I've run into problems if the VirtualBox Extensions pack version differs from the version of VirtualBox. Also, install the Vagrant VirtualBox guest plugin:
vagrant plugin install vagrant-vbguest
And make sure to update the plugin when you update Virtualbox and the extension pack:
vagrant plugin update vagrant-vbguest
Make sure you have vbguest plugin that will keep your guest additions up to date:
vagrant plugin update vagrant-vbguest
If it wasn't installed already, you can install it with:
vagrant plugin install vagrant-vbguest
In VirtualBox window:
(Optional) Note: this step will decrease your vm maximum performance!
You may reduce the general CPU consumption:
I have disabled System Integrity Protection in order to be able to use iosnoop
to diagnose high ioctl
activity, which seems to cause 100% CPU usage.
The problem disappeared. So I believe it has something to do with SIP.