diff options
author | Luke Shumaker <lukeshu@lukeshu.com> | 2018-07-12 00:41:28 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@lukeshu.com> | 2018-08-21 00:51:06 -0400 |
commit | 386c4d38702b2643c09d8db7d7851a39f8798406 (patch) | |
tree | 3295403d934ffeb6bcbd1837d90b090fc2c676e8 /conf.d/qemu.d | |
parent | e3bb3556afb3a612a724095614fade0863a1a667 (diff) |
Add NUMA support and vCPU pinning
Diffstat (limited to 'conf.d/qemu.d')
-rw-r--r-- | conf.d/qemu.d/beefcake | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/conf.d/qemu.d/beefcake b/conf.d/qemu.d/beefcake index 6e671bd..49315cb 100644 --- a/conf.d/qemu.d/beefcake +++ b/conf.d/qemu.d/beefcake @@ -2,17 +2,16 @@ system=x86_64 args=( - #-nodefaults -no-user-config -no-reboot # let the systemd supervisor know we're restarting -machine accel=kvm - -m 32768 # 32 GiB RAM + + -m $((30*1024)) # We have 32 GiB RAM on this socket; leave 2GiB for qemu itself # 1 socket / 8 cores-per-node / 2 threads-per-core = total of 16 CPUs -smp sockets=1,cores=8,threads=2,cpus=16 - # TODO: Split that in to 2 NUMA nodes; 4 cores and 16 GiB RAM each - - #-no-hpet + -numa node,cpus=0-7 + -numa node,cpus=8-15 -uuid 4c42bd65-6ad5-456d-8b76-758ecb795e21 -drive media=disk,file=/dev/vg_build64/lv_beefcake_root,format=raw,if=virtio @@ -24,3 +23,19 @@ args=( -writeconfig /tmp/beefcake.cfg ) + +# numactl=( +# --membind=2,3 +# --cpunodebind=2,3 +# ) +# for i in {0..15}; do +# vcpu2cpulist[$i]=$((16+$i)) +# done + +numactl=( + --membind=0,1 + --cpunodebind=0,1 +) +for i in {0..15}; do + vcpu2cpulist[$i]=$i +done |