Operating System - HP-UX
1834461 Members
2480 Online
110067 Solutions
New Discussion

Re: Number and speed of processors

 
SOLVED
Go to solution
Don Bentz
Regular Advisor

Number and speed of processors

Is there a command I can run that will tell me the number (and speed) of (the) processors on my N4000. I need a command line function so I can pipe the output to a report.
Insecurity is our friend. It keeps you dependent.
7 REPLIES 7
Alexander M. Ermes
Honored Contributor

Re: Number and speed of processors

Hi there
for the number try
sar -M

If you need more details,
try this :

http://members.tripod.com/rose_swe/cfg/cfg.html

Rgds
Alexander M. Ermes
.. and all these memories are going to vanish like tears in the rain! final words from Rutger Hauer in "Blade Runner"
Stefan Farrelly
Honored Contributor
Solution

Re: Number and speed of processors

ioscan -fkNprocessor
shows the number of processors which you can then total.

The following script shows cpuspeed;

let SPEED=`echo "itick_per_tick/D" | adb /stand/vmunix /dev/kmem|grep itick|tail -1|awk '{print $2}'`
if [ $SPEED -lt 0 ];then
echo "/stand/vmunix doesnt match running kernel, trying /stand/vmunix.prev"
let SPEED=`echo "itick_per_tick/D" | adb /stand/vmunix.prev /dev/kmem|grep itick|tail -1|awk '{print $2}'`
let SPEED=$SPEED/10000
if [ $SPEED -lt 0 ];then
echo "/stand/vmunix.prev doesnt match running kernel either, exiting"
exit 1
fi
else
let SPEED=$SPEED/10000
fi
echo "CPU Speed = $SPEED Mhz"
Im from Palmerston North, New Zealand, but somehow ended up in London...
Helen French
Honored Contributor

Re: Number and speed of processors

James R. Ferguson
Acclaimed Contributor

Re: Number and speed of processors

Hi:

For a quick way to tally the number of processors, try:

# sar -M 1 1|awk 'END {print NR-5}'

Regards!

...JRF...
someone_4
Honored Contributor

Re: Number and speed of processors

maybe its just me but i couldnt get
ioscan -fkNprocessor
to work ..
# ioscan -fkN processor
ioscan: illegal option -- N

# ioscan -fk processor
ioscan: Can't open processor: No such file or directory

Richard
harry d brown jr
Honored Contributor

Re: Number and speed of processors

Don,

Have you looked at print_manifest?

live free or die
harry
Live Free or Die
Helen French
Honored Contributor

Re: Number and speed of processors

Hi Don,

Another one: If you have PRM, then use this command to list the number of CPUs:

# prmavail CPU

HTH,
Shiju
Life is a promise, fulfill it!