Re: putting error warnings into seperate mail
2006-05-10 11:05:09
Jon LaBadie wrote:
I'm giving a talk to a local users group this evening.
I just might add that as a "pre-talk" message on the screen.
OK :)
If anyone has use for it, here's the script I came up with:
#! /bin/sh
#
# specify your holding disks
DISKS="/ahodi /home/AHODI"
# specify user who owns files belonging to amanda
AUSR="backup"
# specify users to notify
MLTO="root,backup"
function chk {
RE="$(find $1 -type d -user $AUSR | wc -l)"
}
for i in $DISKS;
do
RE=100
chk $i
if [ "$RE" != "1" ]; then
echo "Files seem to have been left over or removed during a backup
run of amanda. Please check out $i. You eventually need to run amflush."
| mail -s "amanda: WARNING" $MLTO
fi
done
I'll just set up a cron job for it --- and see to have the changer
fixed, it's still under warranty.
Any ideas what else could be checked for? Maybe we can do all of it
outside of amanda.
GH
|
|
|