From 82955ab7eda12602d0debc977b6af55cf77ab438 Mon Sep 17 00:00:00 2001 From: Louwrentius Date: Wed, 21 Oct 2009 20:56:07 +0000 Subject: [PATCH] This version is also detecting CPUs on Solaris. --- branches/distributed-ppss/ppss.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/branches/distributed-ppss/ppss.sh b/branches/distributed-ppss/ppss.sh index 328d3a8..6e897be 100755 --- a/branches/distributed-ppss/ppss.sh +++ b/branches/distributed-ppss/ppss.sh @@ -585,6 +585,10 @@ init_vars () { MODEL=`system_profiler SPHardwareDataType | grep "Processor Name" | cut -d ":" -f 2` SPEED=`system_profiler SPHardwareDataType | grep "Processor Speed" | cut -d ":" -f 2` log INFO "CPU: $MODEL $SPEED" + elif [ "$ARCH" == "SunOS" ] + then + CPU=`psrinfo -v | grep MHz | cut -d " " -f 4,8 | awk '{ printf ("Processor architecture: %s @ %s MHz.\n", $1,$2) }'` + log INFO "CPU: $CPU" else log INFO "CPU: Cannot determine. Provide a patch for your arch!" log INFO "Arch is $ARCH"