UNIX Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsOperating SystemsUNIX Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old January 11th, 2006, 03:29 AM
andrikopoulos andrikopoulos is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2006
Posts: 1 andrikopoulos User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 37 m 53 sec
Reputation Power: 0
How to read my hardware?

Hi all.

i would like to ask if there is a command in HP-UX 11.00 system that gives me information about the memory, the number and the speed of the processors and finally the number of the disks and the disk space. Thanx

Reply With Quote
  #2  
Old January 13th, 2006, 10:04 AM
jim mcnamara jim mcnamara is offline
......@.........
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Jun 2004
Posts: 1,308 jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 3 Days 5 h 21 sec
Reputation Power: 48
swapinfo [options] gives memory information and/or disks
bdf will show you disks

Reply With Quote
  #3  
Old January 14th, 2006, 05:50 PM
Ehlanna's Avatar
Ehlanna Ehlanna is offline
Not a clue what to put ...
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jan 2006
Location: in front of this keyboard
Posts: 814 Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 2 Weeks 2 Days 5 h 10 m 43 sec
Reputation Power: 243
There are ways and means of doing this: the memory and processor speeds need an adb command to find. To get number of disks use ioscan. To find how much disk space I would suggest diskinfo as you may not have all disks attached to a volume group.

Reply With Quote
  #4  
Old January 16th, 2006, 07:52 AM
Ehlanna's Avatar
Ehlanna Ehlanna is offline
Not a clue what to put ...
Dev Shed Novice (500 - 999 posts)
 
Join Date: Jan 2006
Location: in front of this keyboard
Posts: 814 Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level)Ehlanna User rank is Captain (20000 - 30000 Reputation Level) 
Time spent in forums: 2 Weeks 2 Days 5 h 10 m 43 sec
Reputation Power: 243
The following should be good for HP-UX from 10.20 to 11.23 on PA-RISC:

#!/usr/bin/ksh

HPUXReleaseelease=`uname -r`
case $HPUXRelease in
"B.10.20")
KERNELSYMBOL=physmem
NUMERICRELEASE=1020
;;
"B.11.00")
KERNELSYMBOL=phys_mem_pages
NUMERICRELEASE=1100
;;
"B.11.11")
KERNELSYMBOL=phys_mem_pages
NUMERICRELEASE=1111
;;
"B.11.23")
NUMERICRELEASE=1123
;;
*)
echo "Unknown version of OS - assuming 11.00"
KERNELSYMBOL=phys_mem_pages
NUMERICRELEASE=1100
;;
esac
if [ $NUMERICRELEASE -lt 1100 ]
then
OS_BITS=32
else
OS_BITS=`getconf KERNEL_BITS`
fi

echo "You are running HP-UX ${HPUXRelease} in $(OS_BITS} mode"
if [ $NUMERICRELEASE -ge 1123 ]
then
CPU_FOUND=$(echo 'processor_count/D' | adb $(/usr/sbin/kcpath -x) /dev/kmem | tail -1 | awk -F: '{gsub("[\t]+","", $2); print $2}')
else
CPU_FOUND=$(echo 'processor_count/D' | /usr/bin/adb /stand/vmunix /dev/kmem | grep 'processor_count' |tail -n 1 | awk '{print $2}')
fi

echo "You have ${CPU_FOUND} \c"

CPU_VERSION=$(/usr/bin/getconf CPU_VERSION)
case $CPU_VERSION in
523)
echo "PA-RISC 1.0\c"
;;
528)
echo "PA-RISC 1.1\c"
;;
529)
echo "PA-RISC 1.2\c"
;;
532)
echo "PA-RISC 2.0\c"
;;
*)
if [ $CPU_VERSION -ge 523 -a $CPU_VERSION -le 640 ]
then
echo "PA-RISC version not known\c"
else
echo "$CPU_VERSION unknown\c"
fi
;;
esac
echo " running at $(echo 'itick_per_tick/D' | /usr/bin/adb /stand/vmunix /dev/kmem |grep itick_per_tick | tail -1 | awk '{print $2 / 10000}') MHz"

if [ $NUMERICRELEASE -lt 1123 ]
then
REAL_MEMORY=$(echo "$KERNELSYMBOL/D" | /usr/bin/adb /stand/vmunix /dev/kmem | grep "$KERNELSYMBOL" | tail -n 1 | awk '{print $2}')
else
HEXVAL=$(echo "phys_mem_pages/A" | /usr/bin/adb $(/usr/sbin/kcpath -x) /dev/kmem | tail +2| awk '{print $2}')
REAL_MEMORY=$(echo ${HEXVAL}=D| /usr/bin/adb)
fi
MEMORY=$(expr ${REAL_MEMORY} / 256)
echo "You have ${MEMORY}MB memory"

exit

Reply With Quote
  #5  
Old January 16th, 2006, 08:05 AM
christo's Avatar
christo christo is offline
Introspective
Dev Shed Loyal (3000 - 3499 posts)
 
Join Date: Nov 2001
Location: London, UK
Posts: 3,297 christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level)christo User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 3 Days 1 h 9 m 17 sec
Reputation Power: 104
Send a message via ICQ to christo Send a message via Yahoo to christo
istr the 'monitor' command in HP-UX is a nice neat alternative to 'top' which will tell you a fair bit about your system status.


christo

Reply With Quote
Reply

Viewing: Dev Shed ForumsOperating SystemsUNIX Help > How to read my hardware?


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway