As I noted in a previous posting, I did some experiments where I collected processor count information remotely by executing a command with a return code equal to the number of processors. I have gotten a request to share the code I used.
My experiments were done in 2004. I don't know whether all of the commands will work with newer OS levels. The process always involved a scheduled event with 'action=command' and 'object' parameter consisting of an 'exit' command followed by something that evaluates to the number of processors. For Windows I used: object="exit %number_of_processors%" I don't think this works correctly with hyperthreading processors; I think it reports the total number of hyperthreads rather than the number of processors. For Linux I used: object="exit `grep ^processor /proc/cpuinfo|wc -l`" This has the same problem with hyperthreading as my Windows code. However, the /proc/cpuinfo psuedo-file also contained 'sibling' lines reporting the number of hyperthreads per processor. I captured this number using the following: object="exit `grep ^siblings /proc/cpuinfo|head -1|cut -d: -f2`" This code assumes that all of the sibling values are the same. As far as I know, nobody is marketing systems that violate this assumption. For HP-UX I used: object="exit `/etc/ioscan -kC processor|grep processor|wc -l`" For AIX I used: object="exit `lsdev -Cc processor|wc -l`" For Solaris I used: object="exit `/usr/sbin/psrinfo|wc -l`" The Web search that turned up this command also turned up a warning that no known method of querying processor counts works on all Solaris releases. My notes don't indicate theOS level of the system I tested this code on.