Hi,
I have a dual core SMP machine ( in total 4 cores). I have been trying to set restrict vcpu/cpus for my domU to one core/one vpcu but it have not fully worked. As there are two commands "xm vcpu-set" and "xm vcpu-pin". By using these commands, i have observed that the sequence in which they are used plays a role. e.g. I have the following state in the beginning:
[root@lxb ~]# xm vcpu-list
Name                                      ID     VCPUs   CPU   State   Time(s)      CPU Affinity
====         ==     ===== ====  ==== ======     === =====
Domain-0                              0           0              3          r--         5593.4        any cpu
Domain-0                              0           1              1          -b-       15361.9      any cpu
Domain-0                              0           2              0          -b-       10137.5      any cpu
Domain-0                              0           3              -           --p          78.9           any cpu
test_lxb                 20         0              2           -b-       21169.0     any cpu
What I want to achieve is that my domU (test_lxb) uses one VCPU pinned to one CPU. In the above state, both my domU and dom0 are using VCPU 0 (which is pinned to use either CPU 3 or 2.) After few "vcpu-set" and "vcpu-pin", I reach the following stage where dom0 is pinned to CPU 3 and domU (test_lxb) is pinned to CPU 2:
[root@lxb ~]# xm vcpu-list
Name                              ID VCPUs   CPU State   Time(s) CPU Affinity
Name                                      ID     VCPUs   CPU   State   Time(s)      CPU Affinity
====         ==     ===== ====  ==== ======     ========
Domain-0                              0           0             3          r--         5600.4            3
Domain-0                              0           1             3          -b-       15372.5           3
Domain-0                              0           2             3          -b-       10140.0           3
Domain-0                              0           3             -           --p          78.9                3
test_lxb                 20         0             2           -b-       21169.5           2 
But domU is still using VCPU 0 which is also used by my domU; now i would like to restrict VCPU 0 to CPU 2 only for domU only...I am wondering how to achieve this last mile?
Any ideas? Thanks for you help in advance!
Regards
-- 
Omer
-------------------------------------------------------
CERN -- European Organization for Nuclear
Research, IT Department, CH-1211, 
Geneva 23, Switzerland