Gather information on paths to LUNS

#!/bin/sh
#: john core 04-27-07
## gather lad info
#
# save file as get_lad_info.sh
# chmod 755 get_lad_info.sh
# ./get_lad_info.sh
####################

DATE=`date +%m%d%H%M`
TMPFILE=/tmp/${DATE}.txt
touch ${TMPFILE}

echo ""

echo "running healthck -a"
healthck -a >> ${TMPFILE}
echo ""
echo ""

echo \# lad
lad >> ${TMPFILE}

echo ""
echo ""

for ctrl in `lad | awk ‘{print $1}’`
do
echo controller: $ctrl
echo \# drivutil -d $ctrl
drivutil -d $ctrl >> ${TMPFILE}
echo ""
echo \# drivutil -i $ctrl
drivutil -i $ctrl >> ${TMPFILE}
echo ""
echo \# drivutil -I $ctrl
drivutil -I $ctrl >> ${TMPFILE}
echo ""
echo \# drivutil -l $ctrl
drivutil -l $ctrl >> ${TMPFILE}
echo ""
echo \# drivutil -p lun $ctrl
drivutil -p lun $ctrl >> ${TMPFILE}
echo ""
echo \# raidutil -c $ctrl -i
raidutil -c $ctrl -i >> ${TMPFILE}
echo ""
echo \# raidutil -c $ctrl -B
raidutil -c $ctrl -B >> ${TMPFILE}
echo ""
echo \# rdacutil -i $ctrl
rdacutil -i $ctrl >> ${TMPFILE}
echo ""
echo ""
echo ""
done

echo "/etc/osa/rmparams"
echo —————————————————————————
cat /etc/osa/rmparams >> ${TMPFILE}
echo —————————————————————————
echo ""
echo ""
echo "/kernel/drv/sd.conf"
echo —————————————————————————
cat /kernel/drv/sd.conf >> ${TMPFILE}
echo —————————————————————————
echo ""
echo ""
echo "/var/osa/rmlog.log (uuencoded)"
echo —————————————————————————
uudecode -p /var/osa/rmlog.log >> ${TMPFILE}
echo —————————————————————————
echo ""
echo ""
compress ${TMPFILE}

echo "finished!"

echo "file is ${TMPFILE}.Z – please upload to sunsolve with your case number in the name"

exit

Leave a Reply

Your email address will not be published. Required fields are marked *