Hi
When an entry will be made to the file /var/mail/<user-id> .
I have 100 scripts under a specific user id(dgircc) in cron .SO inrder to check the whether the script has sucessfully run or not and if not to generate an email
if i mention the code like
#!/bin/ksh -p
2 fsize=`ls -lrt /var/mail/dgircc |awk '{print $5}'`
3 if [ $fsize -gt 0 ] ;then
4 more /var/mail/dgircc >> /var/mail/dgircc.old
5 uuencode /var/mail/dgircc /var/mail/dgircc | mailx -s "dgircc report " mailid
6 cp /dev/null /var/mail/dgircc
7 fi
will this solve my requirement
Please let me know if there are any good ideas to monitor all the scripts under cron which has failed and to generate a consolidated report of those(which are failed) .