[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Faking the number of CPUs for dom0 with dom0_max_vcpus


  • To: Jimmy Lee <jimmylee4930@xxxxxxxxx>
  • From: Jan Beulich <jbeulich@xxxxxxxx>
  • Date: Mon, 13 Nov 2023 09:00:40 +0100
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=YgNqUJK+kOn7pwQRrVNvuhy02zvzw0/fdgVXwQqXjfg=; b=eFEvhTgPR6dcgp1HdD8Pwav44E1PG8Cq6VtaTAz+60SZDicZzrlmy0G48JNx+gJUCt6GACoJcRSAmoc0cexDI3zKF124vM92BEDY8rENdCpTrGfY7mNvkO4Obz8AKIaDjS/8+hMtikBare+6Ov+PpnreX6Be62DG6sq92PumUsrGXObjcvoi5wie4DHfSUa8+50W+EFa/Sx0HtIFstplbnGTuEYW59dqh5gRT6sp3YIUzq/sm3MFcoW0SIar46PGfbis16YVTFZ61jVD4X7L0Ed4JnQr4ZTW3A3tCBeR4m4tBOP9kNCFE7jykt+dXhcrV5GHBBacYDuZiSghVlx/1A==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=C6jgKyb7YPE0shmVeaf1n0qOS/YXloKjGSgvHIbtxJWVJoMbZ5Z5q7VxIoTJ+ruQU4TrwQPis+KgBhe0oY1/FDP+UBGlfgV88FC7+eqzgAasr6T875dTZ6MpLs6iBET3lJ63XHqZeWt3dhn5uub750LBqIUf1YcnafPTKEBqtcIlrMe65YkkX71uCoQpqSZOPFh1fmRmuK6o0TgkCyeEHr/BfFl1pxwH/OaYPJlaRO3kpoU3A7XAAiB29b4XnQGmye/JcVl5YhJAvsAfPlbAXp0V33ScHEMr/KUaEdskemrEMuMDQeXUqoE7UKYVXK0z9KqZzBYgJrw37F1nTrXyzQ==
  • Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
  • Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx
  • Delivery-date: Mon, 13 Nov 2023 08:00:54 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On 12.11.2023 21:28, Jimmy Lee wrote:
> Hello Xen experts, I am trying to set dom0_max_vcpus to a number that is
> larger than the number of pcpus. For example, I have a 4-CPU machine but I
> want applications in dom0 to have an illusion that they are running on a
> 64-cpu machine. However, it seems that dom0 will always recognize the
> number of pcpus. I can see the vcpus in the output of "xl vcpu-list" but
> most of them are not online. How can I achieve my goal? Thanks!

Even if I was to assume the Dom0 kernel is Linux, it would still remain
unclear what Linux version you use. Generally with recent Linux kernels
this has been working for me (albeit I didn't try in a while, after
putting together what has become e25a8d959992 ["x86/Xen: streamline (and
fix) PV CPU enumeration"]). If despite having this in your Linux you
still don't see this working, you will want to supply applicable logs.

As an aside - 64 vCPU-s on a 4-pCPU system looks excessive to me.

Jan

> [root@ip-10-0-131-61 cpu3]# xl vcpu-list
>> Name                                ID  VCPU   CPU State   Time(s)
>> Affinity (Hard / Soft)
>> Domain-0                             0     0    0   r--      15.9  all /
>> all
>> Domain-0                             0     1    3   -b-      11.9  all /
>> all
>> Domain-0                             0     2    1   -b-      11.2  all /
>> all
>> Domain-0                             0     3    2   -b-      12.4  all /
>> all
>> Domain-0                             0     4    -   --p       0.0  all /
>> all
>> Domain-0                             0     5    -   --p       0.0  all /
>> all
>> Domain-0                             0     6    -   --p       0.0  all /
>> all
>> Domain-0                             0     7    -   --p       0.0  all /
>> all
>> Domain-0                             0     8    -   --p       0.0  all /
>> all
>> ....
>>
> 
> [root@ip-10-0-131-61 cpu3]# lscpu
> Architecture:          x86_64
> CPU op-mode(s):        32-bit, 64-bit
> Byte Order:            Little Endian
> CPU(s):                4
> On-line CPU(s) list:   0-3
> Thread(s) per core:    4
> Core(s) per socket:    1
> Socket(s):             1
> NUMA node(s):          1
> ...
> 
> [root@ip-10-0-131-61 cpu3]# xl info
> ...
> xen_commandline        : placeholder dom0_mem=3%,min:2G,max:4G
> com1=115200,8n1 console=com1,tty,vga dom0_max_vcpus=64 spec-ctrl=no
> sched=credit vcpu_migration_delay=1000 allowsuperpage ioapic_ack=new
> ...
> 




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.