1833013 Members
2400 Online
110048 Solutions
New Discussion

Re: No of CPU

 
Sanjeev gupta_2
Frequent Advisor

No of CPU

Hi All
From which command i may know how many CPU on my system.

Thx
6 REPLIES 6
Victor BERRIDGE
Honored Contributor

Re: No of CPU

The easyest way is to type top...

All the best
Victor
John Poff
Honored Contributor

Re: No of CPU

Hi,

One way to do it:

ioscan -fnC processor

JP
Victor BERRIDGE
Honored Contributor

Re: No of CPU

Then you could try:
# dmesg|grep processor
160 processor
166 processor


Regards
Jeff_Traigle
Honored Contributor

Re: No of CPU

And yet another way...

echo processor_count/D | adb -k /stand/vmunix /dev/kmem | tail -1 | awk '{print $2}'
--
Jeff Traigle
Dave Olker
Neighborhood Moderator

Re: No of CPU

Since dmesg is a circular buffer, the processor information may no longer be there, but you could do a similar search through the syslog:

# grep processor /var/adm/syslog/syslog.log
Jul 30 14:37:42 hpatcux9 vmunix: 120 processor
Jul 30 14:37:42 hpatcux9 vmunix: 121 processor
Jul 30 14:37:42 hpatcux9 vmunix: 122 processor
Jul 30 14:37:42 hpatcux9 vmunix: 123 processor

This shows my system is a 4-way system. One thing these commands doesn't take into account is "deactivated" CPUs. For this reason, I typically use crashinfo to get CPU information. On my server, crashinfo shows:

System Name : HP-UX
Node Name : hpatcux9
Model : server rx5670
HP-UX version : B.11.23
Number of CPU's : 4
Disabled CPU's : 0
CPU type : IA64 (999 Mhz)
CPU Architecture : IA-64 0
Load average : 0.07 0.02 0.01

I get the number of CPUs, the number of disabled CPUs, the type, architecture, and speed of the CPUs.

Regards,

Dave


I work at HPE
HPE Support Center offers support for your HPE services and products when and how you need it. Get started with HPE Support Center today.
[Any personal opinions expressed are mine, and not official statements on behalf of Hewlett Packard Enterprise]
Accept or Kudo
Jean-Luc Oudart
Honored Contributor

Re: No of CPU

with SAM

SAM -> Performance monitor -> System properties : view the processor section

Regards,
Jean-Luc
fiat lux