Is there a better way to get sockets, cores, and threads working with IceHouse?

asked 2015-09-23 16:31:22 -0500

zephar42 gravatar image

updated 2015-09-23 18:27:02 -0500

smaffulli gravatar image

When I launch a Windows image using Ice House, it only gives me 4 cores instead of the 22 cores I originally assigned in the flavor.

This is because Windows can only apply 4 cores to 1 socket. I found a way to modify the /usr/lib/python2.6/site-pacakges/nova/virt/libvirt/ file to get this to work, but I need to make this change to each compute node.

1) Comment out line 2892

# guestcpu.match=exact

2) Add in guest.cpu parameters After line 3126, add the following...

guest.cpu.sockets = 3

guest.cpu.cores = 7

guest.threads = 2 (check if your cpu's support hyper threading)

Note: Spacing matters.. use spaces and not tabs, and make sure to use spaces on either side of the equals.

3) Also, make sure total vcpus is set right. In my case, I changed the vpcu to 42 in the flavor (372=42), however you could hard code it here too.


4) Hard Reboot I also needed to hard reboot the instance for the change to take effect.

This allows Windows to boot with 42 cores, however, is there a cleaner way to do this? Also, the dashboard says I'm using 42 cores on a hyperviser with 24 cores. Doesn't quite add up, but it works! :)

It looks like Juno can do this in the flavor with extra_specs... (

However, is there a better way to change the values (sockets, cores, threads) dynamically without having to redeploy when the flavor changes?



edit retag flag offensive close merge delete