I set up an rsync with cron to backup files on a freebsd 8.0
using below code:
But there is a problem when I scheduled it using Cron Jobs in the Freebsd
The /mnt/BACKUP is a mounted Network Storage(NAS)
Please advise
using below code:
Code:
SRCDIR="/home/users"
BACKUPDIR="/mnt/BACKUP"
LOGERRFILE="/<some_path>/file_users_logERR.txt"
LOGOKFILE="/<some_path>/file_users_logOK.txt"
if [ ! -d "$BACKUPLOC" ]; then
mount_smbfs -I <ip_address> -L en_US.ISO8859-1 -W Workgroup -N //guest@<ip_address>/Volume_1/ /mnt/BACKUP
fi
echo "" > "$LOGERRFILE"
/usr/local/bin/rsync -avzh --progress --iconv=UTF-8,ISO8859-1 "$SRCDIR" "$BACKUPDIR" 2> "$LOGERRFILE" > "$LOGOKFILE"
if [ -s "$LOGERRFILE" ]; then
//send email
exit 1
fi
But there is a problem when I scheduled it using Cron Jobs in the Freebsd
Code:
rsync: mkstemp ... failed: Operation timed out (60)
rsync: recv_generator: .... class": Operation timed out (60
The /mnt/BACKUP is a mounted Network Storage(NAS)
Please advise