Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

On unix, how could we know whether the system is multiprocessor or uniprocessor?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
734 views
Welcome To Ask or Share your Answers For Others

1 Answer

Some times we have to answer owr own question :)

On Solaris run the command

/usr/sbin/psrinfo -v|grep "Status of processor"|wc -l

On AIX run the command

lsdev -C|grep Process|wc -l

On HP-UX run the following commands (requires superuser privileges):

P=`echo processor_count/D | adb -k /stand/vmunix /dev/mem |tail -1|awk '{print $2}'` echo "The number of processors on `hostname` = $P"

On Tru64 run the command

 /usr/sbin/psrinfo -v|grep "Status of processor"|wc -l

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...