Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

/nsr/logs/messages

Status
Not open for further replies.

hpuxdba

Technical User
Mar 27, 2002
3
GB
Hi

I am trying to write a script to pull out all errors from the messages for that day.

can anyone help please

Steve
 
what platform are you on unix/NT/Other?
Mike davison
mike.davison@avon.com
 
Hi
Yeah it is ruuning on unix (hp ux 11.00 with legato 6.1 )

I have written the following but i need more detail as i will run from cron every morning then if error's are found email me.

script i have created :
#!/usr/bin/sh
clear

LOGDIR=/nsr/logs/messages


if [ "$LOGNAME" != "root" ]; then
echo "Error: You must be user root to run this script!" >&2
exit 1
fi
sleep 2

print Welcome $LOGNAME
print "SEARCH IN PROGRESS............."
sleep 2

clear

grep -i SETS /nsr/logs/messages

if [ `grep -i "Unsuccessful Save Sets" /nsr/logs/messages200302 | wc -l` -gt 0 ];
then
echo " There was a problem with the backup "

else

echo " Backup completed "
Regards
Steve
 
Hi,

We use mminfo to get backup status codes. The logs are ok, but if a client doesn't run, or a group doesn't start, you probably won't know anything about it.

If you still want to use the logs, check for file changes during backup. Most are normal, but if someone creates a new db ona server, and backups are not setup for it, a recovery may not be easy (or possible)...

Good Luck!

-ag100
 
Most error messages / warnings have a "*" on the error line, so you can search for that also..
Mike davison
mike.davison@avon.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top