script issue for cronjob [message #149331] |
Thu, 01 December 2005 05:13 |
alanm
Messages: 284 Registered: March 2005
|
Senior Member |
|
|
Hello All,
I am trying to get a script to email me when errors occur in an RMAN backup script. the segment of script giving the issue is
grep "error" /tmp/rman_backup.txt >alert_rman
#
if [ -s alert_rman]
then
mailx -s "ALERT -> vaildate database $DB" $MAILLIST
else
mailx -s "Status -> vaildate database restore ok" $MAILLIST
fi
if I look at alert_rman it contains errors yet the script will only return the ELSE part of the statement.
regards
Alan.
|
|
|
|
|
|