Using custom scripts before and after backups
You can configure custom scripts will run before or after a backup.
Scheduled backups can be configured to run custom scripts before and after the backup is
performed. These custom scripts need to be located in
/usr/share/datastax-agent/bin/backup-scripts for package installations, or
in <install_location>/bin/backup-scripts for tarball
installations. This directory also contains example scripts. The scripts need to be executable,
and are run as the DataStax agent user (by default datastax-agent
). Any custom
scripts should exit with a status of 0 if all operations completed successfully. Otherwise, it
should exit with a non-zero status to indicate a failure.
Post-backup scripts are sent a list of files in the backup to stdin
, one file
per line, but will not have any arguments passed to them.