bhyve behavior under cpuset_setaffinity

Peter Grehan grehan at freebsd.org
Sun Apr 27 15:21:06 UTC 2014


Hi Oleg,

> For example by executing follow command on bhyve pid:
>
> % cpuset -l 2 -p 3476

>    3476 vcpu 0   RET   ioctl 0
  ...
>    3476 vcpu 1   RET   ioctl 0

  Looks like you have a 2 vCPU guest, but the cpuset only contains a 
single host CPU. What happens here under load is that you will start 
hitting "lock-holder preemption", where a vCPU can be preempted while 
holding a lock, and the other vCPU will spin trying to acquire it.

  Using the "-P" option with bhyve will help this somewhat, though I'd 
recommend using >= 2 CPUs with the cpuset command.

later,

Peter.


More information about the freebsd-virtualization mailing list