Thanks to all who helped!
I've created a /root/headers directory with files containing email headers for each logfile that I wish the machine to email me, each named with the same name as the logfile. Then, I have added 3 lines to multicron-d like so:
rotatelogs () {
case $prog in
*-d ) LOGFILES=$lrp_LOGS_DAILY ;;
*-w ) LOGFILES=$lrp_LOGS_WEEKLY ;;
*-m ) LOGFILES=$lrp_LOGS_MONTHLY ;;
* ) return 1 ;;
esac
cd /var/log
for LOG in $LOGFILES; do
if [ -f $LOG ]; then
> if [-f /root/headers/$LOG ]; then
> cat /root/headers/$LOG $LOG | ssmtp [EMAIL PROTECTED]
> fi
savelog -g adm -m 640 -u root -c ${lrp_LOGS_DEPTH:-4} $LOG >/dev/null
fi
done
svi sysklogd reload
}
This seems to work -- is this some awful kludge that I should have done in another way?
Thanks again, and especially to David and Charles for all their fine work.
--Merrick Munday
