Question

I am trying to pin my domU to 15 CPUs (16-31) on a 64-core machine. I have booted the system with the following kernel options: dom0_vcpu_pin=true

and then later with "xm vcpu-pin domU vpu 16-31" I was able to set CPU affinity to fifteen CPU's but still the domU is only using one CPU and the rest are in paused state. Can someone provide more details how to sort this out so that I could see my domU using more CPU's via "xm vcpu-list".

Thanks.

Was it helpful?

Solution

One have to set the following options in the xen config file:

maxvcpus= # vcpus = # vcpu_avail = bitmask for vcpu activation e.g. 24=11000 and will activate vcpu0,vcpu1 only.

Also there is a bug in xm/create.py. The following patch fixed the issue for me and after this bitmask value was activating required vpcu's read from the xen configuration file. Prior to that, vpcu_avail was always set to '1' (also verified from 'xenstore-ls -f' output).

--- create.py   
+++ create.py.af  

         if maxvcpus and vcpus:
             config.append(['vcpus', vcpus])
-            config.append(['vcpu_avail', (1 << vcpus) -1)])
+            config.append(['vcpu_avail', getattr(vals, 'vcpu_avail'])

     def add_conf(n):
         if hasattr(vals, n):
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top