[RC5] How to detect the number of processors on a UNIX

Joe Zbiciak j-zbiciak1 at ti.com
Thu Jan 29 00:43:31 EST 1998


system?
Sender: owner-rc5 at lists.distributed.net
Precedence: bulk
Reply-To: rc5

'Chris Vanden Berghe' said previously:
| 
| I've got rc564-solaris251-6403-320-mt running on a multiprocessor system
| (min 8), but I don't know how many processors it contains.  So sue me 
;-)
| If there is no way of asking anybody, what is the best number to number 
to
| use for the numcpu option?
| 

You could use "dmesg" to print out the "boot up" messages that your 
machine
issues.  For instance, the Sparc 20 on my desk states the following 
towards
the top of its dmesg output:

SunOS Release 5.5.1 Version Generic [UNIX(R) System V Release 4.0]
Copyright (c) 1983-1996, Sun Microsystems, Inc.
pac: enabled - SuperSPARC/SuperCache
cpu0: TI,TMS390Z55 (mid 8 impl 0x0 ver 0x8 clock 75 MHz)
cpu1: TI,TMS390Z55 (mid 10 impl 0x0 ver 0x8 clock 75 MHz)

So, I know I have two CPUs.

I'd guess running "dmesg | grep ^cpu" would cut right to the chase.  For
instance, on this same machine, I get this output:

cpu0: TI,TMS390Z55 (mid 8 impl 0x0 ver 0x8 clock 75 MHz)
cpu1: TI,TMS390Z55 (mid 10 impl 0x0 ver 0x8 clock 75 MHz)
cpu 0 initialization complete - online
cpu 2 initialization complete - online


Good luck, and happy cracking.

--Joe

-- 
 +----------- Joseph Zbiciak ----------+
 | - - - -  j-zbiciak1 at ti.com  - - - - |  Join your idle CPU cycles into 
the
 |- http://www.primenet.com/~im14u2c/ -|  world's largest supercomputer:
 | - - -Texas Instruments, Dallas- - - |  http://www.distributed.net/
 +-----#include <std_disclaimer.h>-----+

--
To unsubcribe, send 'unsubscribe rc5' to majordomo at lists.distributed.net
rc5-digest subscribers replace rc5 with rc5-digest



More information about the rc5 mailing list