Secure backup is the only way to backup the entire DataPower device, including its keys and certificates, so it has to be performed on a periodic basis. This can be easily automated using DPBuddy. Here is an example:
dpbuddy secureBackup -cert dp-backup -toDir sbackups/backup -appendTimestamp
Here is the same example using Ant:
<dp:secureBackup cert="dp-backup" toDir="sbackups/backup" appendTimestamp="true" />
This command does a few things:
It is also possible to backup multiple devices with a single command:
dpbuddy secureBackup -cert dp-backup -toDir 'sbackups/${dpEnv}/backup' -appendTimestamp -env "dev,test"
DPBuddy will resolve “dpEnv” to the name of the environment/device and create the appropriate directory structure so that all backups for a particular device reside in one place.
DPBuddy also fully supports secure restore. You can use this feature for keeping your appliances in sync, especially in the case of disaster recovery (DR) appliances. Create a secure backup on a periodic basis or after a change and restore it into your DR appliance. Note: restoring secure backup overrides network settings, so you’ll need to use DHCP or a similar mechanism to manage it:
dpbuddy secureBackup -cert dp-backup -toDir sbackups/sync dpbuddy secureRestore -cred dp-restore -dir sbackups/sync -waitForReboot -env dr
If “-waitForReboot” is specified, “secureRestore” will wait for the appliance to complete the reboot triggered by restore.
It is also worth mentioning that DPBuddy deals with file downloads and uploads in an efficient manner — the files are streamed directly to/from disk and never loaded into memory. This means that the secure backup/restore tasks can accommodate backup of any size (subject to the available space on the device).
For more information, please refer to our documentation for secure backup/restore.
If you’re interested in automating the rest of your DataPower deployment and administration tasks, download DPBuddy and give it a try. Here you can find various examples of DPBuddy’s tasks, including backup/restore-related examples.
Automate without scripting, monitor your services, check for compliance
Realize full potential of DataPower gateways