MethodMan1972
IS-IT--Management
...the spec of a server. What commands will best produce a list of the server specs, as in number of processors and speed, memory, storage, disk etc...?
Many thanks
Many thanks
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
#Colrept - AIX system reporting
print_usage()
{
echo "Usage: " $0 " [Short|Long]"
}
#Check parameter
case $1 in
[L,l][O,o][N,n][G,g])
# Long version
CFGFLGS="-vl"
;;
[S,s][H,h][O,o][R,r][T,t])
# Short Version
CFGFLGS="-l"
;;
*)
# Error condition
print_usage
exit 1
;;
esac
echo "System Information for `uname -n`"
echo "Report run on `date`\n"
echo "Hardware Configuration"
echo "\nModel Name"
PROCTYPE=`lsattr -El sys0 -a modelname | awk '{ print $2 }'`
echo $PROCTYPE
echo "Firmware Revision level"
#lsattr -El sys0 -a fwversion | awk '{print $2}'
case $PROCTYPE in
IBM,7044-270|IBM,7107-S80)
lscfg -vp | grep alter | sed 's/\.\{2,\}/,/g' | awk -F, '{print $2 }';;
IBM,7025-F80)
lscfg -vp | grep -F .CL | sed 's/\.\{2,\}/,/g' | awk -F, '{print $2 }';;
IBM,7026-M80)
lscfg -vp | grep -F .MM | sed 's/\.\{2,\}/,/g' | awk -F, '{print $2 }';;
IBM,7026-H80)
lscfg -vp | grep -F .CM | sed 's/\.\{2,\}/,/g' | awk -F, '{print $2 }';;
*)
echo "Unable to provide firmware revision level";;
esac
echo "\nProcessor details"
for proc in `lsdev -C | grep Available | grep proc | cut -c1-11`
do
echo $proc "\c"
lsattr -El $proc | grep ^type | awk '{print $2}'
done
echo "\nOS level" `oslevel`
OSML=`oslevel -r`
if [ $? -eq 0 ]
then
echo "Maintenance Level " $OSML
else
echo "No maintenance packs installed"
fi
echo "Incomplete known maintenance level fixes"
instfix -i | grep ML | awk '/^ Not/ {print $5}'
echo "\nMemory details"
#lsattr -EHl mem0
echo `bootinfo -r | awk '{print $1/1024}'` "Mb"
echo "\nDevices Installed"
echo "Local Hard Disks"
lscfg ${CFGFLGS} hdisk\*
echo "Connected hard disks"
lscfg ${CFGFLGS} pdisk\*
echo "CD drives"
lscfg ${CFGFLGS} cd\*
echo "Tape Drives"
lscfg ${CFGFLGS} rmt\*
echo "Floppy drives"
lscfg ${CFGFLGS} fd\*
echo "Ethernet Adapters"
lscfg ${CFGFLGS} ent\*
echo "SCSI Controllers"
lscfg ${CFGFLGS} scsi\*
echo "\nHard Disks installed"
#lspv
for disk in `lspv | awk '{print $1}'`
do
echo $disk `bootinfo -s $disk | awk '{print $1/1024}'` Gb
done
echo "\nNetwork Cards"
for interface in `ifconfig -l`
do
echo $interface `ifconfig $interface | awk 'NR!=1{print $2}'`
done
echo "\nVolume groups configured"
lsvg
echo "\nVolume group details"
for VolGrp in `lsvg`
do
lsvg $VolGrp
echo
done
echo "\nHard disks per Volume Group"
for VolGrp in `lsvg`
do
echo "Disks in $VolGrp"
lsvg -p $VolGrp | awk 'NR != 1 { print }'
echo
done
echo "\nFile systems configured"
for VolGrp in `lsvg`
do
echo "File systems in $VolGrp"
lsvg -l $VolGrp | awk 'NR != 1 { print }'
echo
done
echo "\nFile system usage"
#awk 'BEGIN {printf ( "%-20s\t%s\t%s\t%s\n", "File System", "Total Mb", "Free Mb", "Mount Point")}'
df -Ik | grep -v Filesystem | awk 'BEGIN {printf ( "%-20s\t%s\t%s\t%s\n", "File System", "Total Mb", "Free Mb", "Mount Point")}{ printf ("%-20s\t%.2f\t\t%.2f\t%s\n", $1, $2/1024, $4/1024, $6 )}'