微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

如何找出我的XEN系统有多less个CPUvcpus?

如果我从头开始或者查看/proc/cpuinfo ,我只能看到两个cpu。 如果我用virt-manager查看我的系统显示的值,该工具显示我32 vcpus(这是我认为是正确的值)。

我没有(还)在虚拟机pipe理程序的脚本级别发现正确的值(32)。 我一直在寻找/proc/cpuinfo和/sys/devices/system/cpu/和其他我能想到的东西,但发现价值无处。 另外像xen或xm这样的shell命令我仔细检查过,但没有办法显示我正在查找的值。

有谁知道我可以找出多lessvcpus我的XEN系统提供?

编辑: lscpu给我:

访问冲突exception如何触发

快速cpu环形模式保护问题

时间花在cpu上比现实中更快

如何人为地将cpu加载到一定的百分点?

如何使用Intel Pin工具生成分支机构列表?

Architecture: x86_64 cpu op-mode(s): 32-bit,64-bit Byte Order: Little Endian cpu(s): 2 On-line cpu(s) list: 0,1 Thread(s) per core: 2 Core(s) per socket: 1 Socket(s): 1 NUMA node(s): 1 vendor ID: GenuineIntel cpu family: 6 Model: 45 Stepping: 7 cpu MHz: 2900.086 BogoMIPS: 5800.17 Hypervisor vendor: Xen Virtualization type: none L1d cache: 32K L1i cache: 32K L2 cache: 256K L3 cache: 20480K NUMA node0 cpu(s): 0,1

所以,这也不会在任何地方显示“32”。

/proc/cpuinfo的内容

processor : 0 vendor_id : GenuineIntel cpu family : 6 model : 45 model name : Intel(R) Xeon(R) cpu E5-2690 0 @ 2.90GHz stepping : 7 microcode : 0x70d cpu MHz : 2900.086 cache size : 20480 KB physical id : 0 siblings : 2 core id : 0 cpu cores : 1 apicid : 0 initial apicid : 0 fpu : yes fpu_exception : yes cpuid level : 13 wp : yes flags : fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht syscall nx lm constant_tsc rep_good nopl nonstop_tsc pni pclmulqdq est ssse3 cx16 sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes hypervisor lahf_lm ida arat pln pts dtherm bogomips : 5800.17 clflush size : 64 cache_alignment : 64 address sizes : 46 bits physical,48 bits virtual power management: processor : 1 vendor_id : GenuineIntel cpu family : 6 model : 45 model name : Intel(R) Xeon(R) cpu E5-2690 0 @ 2.90GHz stepping : 7 microcode : 0x70d cpu MHz : 2900.086 cache size : 20480 KB physical id : 0 siblings : 2 core id : 0 cpu cores : 1 apicid : 1 initial apicid : 1 fpu : yes fpu_exception : yes cpuid level : 13 wp : yes flags : fpu de tsc msr pae cx8 apic sep cmov pat clflush acpi mmx fxsr sse sse2 ss ht syscall nx lm constant_tsc rep_good nopl nonstop_tsc pni pclmulqdq est ssse3 cx16 sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes hypervisor lahf_lm ida arat pln pts dtherm bogomips : 5800.17 clflush size : 64 cache_alignment : 64 address sizes : 46 bits physical,48 bits virtual power management:

Linux内核中virt_to_phys和cpu的MMU之间的关系是什么?

perf的选项来衡量用户和内核级别的事件是什么意思?

如何在没有root权限的情况下在Linux下获得cpu串口

cpu如何从磁盘读取?

时钟在Windows 7中如何工作?

我现在找到了一个方法

IFS=: read _ nr_cpus < <(xm info | grep ^nr_cpus) echo "$nr_cpus"

这将(最后)打印

32

在我的系统上。

这是一个不错的方法

cat /proc/cpuinfo | grep "core id"

这是输出一个例子:

core id : 0 core id : 1 core id : 0 core id : 1

在我的情况下,系统是双核的,我只有core-id 0和core-id 1。

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐