#!/bin/sh

# This is a sample cron job to kick off backups with amanda.

# Run the tape tests on DailySet first, and if ok, then kick off backups
# Mail error reports to root

# Ensure TAPE is set to your tape drive for mt to work, ie. TAPE="/dev/st0"

ADMIN_EMAIL="root@localhost"

/usr/sbin/amcheck -t -m -M"${ADMIN_EMAIL}" DailySet1 && \
( /usr/sbin/amdump DailySet1 ; /usr/sbin/mt eject )
