Displaying 1 result from an estimated 1 matches for "rsync_zfs_rotate".
2009 Oct 08
0
rsync+zfs rotate script
...e trailing slashes just like in rsync
# third argument is which pool to use (ie. tank)
# fourth argument is what ZFS fileystem on that pool (ie server1/home)
# fifth argument is how many snapshots for this zfs filesystem
RMT_SERVER=$1
RMT_TARGET=$2
LCL_POOL=$3
LCL_ZFS=$4
SNAPCOUNT=$5
OUTFILE=/tmp/rsync_zfs_rotate-${LCL_POOL}-${LCL_ZFS}.log
ERRFILE=/tmp/rsync_zfs_rotate-${LCL_POOL}-${LCL_ZFS}.err
MAILER=/usr/sbin/sendmail
MAILTO=someone at domain.com
# NO EDITS BELOW THIS
###################################################
# remove any old ERRFILE/OUTFILE to start fresh
rm -f ${OUTFILE}
rm -f ${ERRFILE}
e...