Suresh_Jo_32729
Aug 02, 2018Nimbostratus
Auto back script in cron shell
All,
I have deployed one script in ltm running in 12.1.2 for auto backup in cron shell. I am not getting the desired result. Can someone pls check and let me know what corrections are required in the script.
Script:
vi backup.sh
!/bin/bash
daily_backup.sh HOST=$HOSTNAME DATE=date +%m%d LDIR="/var/local/ucs/" DDIR="/var/local/ucs/daily/" tmsh save sys ucs $LDIR$HOST.ucs mv $LDIR$HOST.ucs $DDIR$HOST.$DATE.ucs /usr/bin/find /var/local/ucs/daily/ -mtime +45 -exec rm {} \; USER=xxxx PASS=xxxx cd $DDIR ftp -nv xxxx.com exit 1
and then add the crontab -e command and add in this line 20 23 * * * bash /var/scripts/daily_backup.sh
Also how I can check if the config file is generating in ltm locally?