Forum Discussion
Automatic weekly backup transfer to FTP
Hi , I have configured 00 3 * * * tmsh save /sys ucs /var/ucs/XYZ. ucs in crontab -e and weekly backup is working fine in local . Now I need to schedule automatically transfer to backup files to FTP server .
Got the script from devcentral for FTP transfer
$DATE=
date "+%m_%d_%y"
Here we create the ucs archive
tmsh save sys ucs $DATE
Here we copy it to your server with scp
scp /var/local/ucs/$DATE user@ip_server:path
Here we do the same with ftp
ftp -n your_server <
Now I am little bit confused where to write this script and how it will relate to cronjob ?? Can anybody help on this .
Regds.....
- Kevin_StewartEmployee
Instead of specifying the tmsh command in crontab, specify a Bash script that 1) performs the tmsh archive, and then 2) FTPs it to the remote destination.
- Kevin_StewartEmployee
This is a very minimal Bash script with no error checking, but should give you a good start:
!/bin/bash today_ucs="`date "+%m_%d_%y"`.ucs" dir=`pwd` tmsh save /sys ucs $dir/$today_ucs ftp -n <
Give this Bash script a name and reference it in crontab.
- vincent119_9651Nimbostratus
http://vincent119.blogspot.tw/2007/05/backup-f5-bigip-config.html
Recent Discussions
Related Content
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com