Listing 5 wrapper script
#!/bin/sh
#
# wrapper.sh -- a wrapper script that calls my awk scripts and prints out
# useful system info.
#
# copyright (c) 2001 jose nazario
#
# logfile location are assumed to be the default locations
# IRIX: /var/adm/SYSLOG, /var/adm/sulog (no mail.log)
# HPUX: /var/adm/syslog/syslog.log, /var/adm/sulog
# Solaris: /var/adm/messages
# Linux: /var/log/messages, /var/log/maillog, (no sulog)
#
# system header info
uname -a
date
echo ""
# snapshot info
w
echo ""
# Linux uses old BSD syntax
ps aux
# IRIX, Solaris, HPUX 10.20 use SysV syntax
#ps -ael
echo ""
# network config stuff
# use ifconfig -a for solaris, IRIX
ifconfig -a
# use ifconfig for Linux to list all devices
# ifconfig
# use lanscan for HPUX
# lanscan
echo ""
netstat -na
echo ""
netstat -nr
# disk stats
df -k
# on HPUX use bdf
# bdf
echo ""
mount
# who has been logging in
echo ""
last | head -25
# password file check
ls -l /etc/passwd
echo ""
pw.check /etc/passwd
sulog.check /var/adm/sulog
sendmail.check /var/log/mail.log
syslog.check /var/log/messages
|