F5 Automated Backups - The Right Way
Hi all,
Often I've been scouring the devcentral fora and codeshares to find that one piece of handywork that will drastically simplify my automated backup needs on F5 devices. Based on the works of Jason Rahm in his post "Third Time's the Charm: BIG-IP Backups Simplified with iCall" on the 26th of June 2013, I went ahead and created my own iApp that pretty much provides the answers for all my backup-needs.
Here's a feature list of this iApp:
- It allows you to choose between both UCS or SCF as backup-types. (whilst providing ample warnings about SCF not being a very good restore-option due to the incompleteness in some cases)
- It allows you to provide a passphrase for the UCS archives (the standard GUI also does this, so the iApp should too)
- It allows you to not include the private keys (same thing: standard GUI does it, so the iApp does it too)
- It allows you to set a Backup Schedule for every X minutes/hours/days/weeks/months or a custom selection of days in the week
- It allows you to set the exact time, minute of the hour, day of the week or day of the month when the backup should be performed (depending on the usefulness with regards to the schedule type)
- It allows you to transfer the backup files to external devices using 4 different protocols, next to providing local storage on the device itself
- SCP (username/private key without password)
- SFTP (username/private key without password)
- FTP (username/password)
- SMB (using smbclient, with username/password)
- Local Storage (/var/local/ucs or /var/local/scf)
- It stores all passwords and private keys in a secure fashion: encrypted by the master key of the unit (f5mku), rendering it safe to store the backups, including the credentials off-box
- It has a configurable automatic pruning function for the Local Storage option, so the disk doesn't fill up (i.e. keep last X backup files)
- It allows you to configure the filename using the date/time wildcards from the tcl [clock] command, as well as providing a variable to include the hostname
- It requires only the WebGUI to establish the configuration you desire
- It allows you to disable the processes for automated backup, without you having to remove the Application Service or losing any previously entered settings
- For the external shellscripts it automatically generates, the credentials are stored in encrypted form (using the master key)
- It allows you to no longer be required to make modifications on the linux command line to get your automated backups running after an RMA or restore operation
- It cleans up after itself, which means there are no extraneous shellscripts or status files lingering around after the scripts execute
I wasn't able to upload the iApp template to this article, so I threw it on pastebin: http://pastebin.com/YbDj3eMN
Enjoy!
Thomas Schockaert
- Daniel_TavernieCirrostratus
Check out GitHub for the latest version of the F5 Automated Backup iApp, and submit any bugs or questions as an "Issue" on GitHub:
https://github.com/tabernarious/f5-automated-backup-iapp
- DCNNimbostratus
will it work on version 11.6?
- NdlovummCirrus
Thanks for the code....works like a charm on version 13
- theguruNimbostratus
Does this work on BIG-IP v14.1.0.3 (Build 0.0.6)? Or anything 14.1?
- Gilberto_383328Nimbostratus
Hi:
I have install the iApp and is so usefull. But I can see the next logs just in version 14.1.0.x.
"exec $scriptfile" line
This kind of logs appear every minute, Do you know if the problem could affect my device?
- aries22Altocumulus
Hi! First off, thank you very much for sharing this. So cool and super helpful!
Can anyone tell me what the field "Amount of files to keep at any given time:" is for? I thought this was in relation to automatic pruning - will only prune files exceeding the value for this field, however it seems it is not for this purpose.
- Nyam_220167Nimbostratus
Hi Tabernarious, Please check the bipip version
Sys::Version Main Package Product BIG-IP Version 13.1.0.4 Build 0.0.6 Edition Point Release 4 Date Tue Mar 13 20:10:42 PDT 2018
I don't have Github account i will create it and let you know.
- Daniel_TavernieCirrostratus
@Nyam, I’ve attempted to replicate your issue with various combinations and have consistently seen the Standby generate and store backups as expected. If you have t already, I would recommend to delete the Application Service, Sync, then rebuild it.
If you have a Github account please create an Issue there for this project and we can troubleshoot further.
- Nyam_220167Nimbostratus
Hello tabernarious, even with v3.1.9 backup's are not happening on the standby device. I can see the backup only for active unit.
- Nyam_220167Nimbostratus
Sure...let me check and get back to you.