Here is an example of how to set up a backup going to Backblaze B2 bucket using rclone.
Login to Backblaze, create a new bucket, create a new Application Key. Set your retention and lifecycle settings as desired to keep old versions of files. Run this: rclone config set up your new B2 Application Key details. Create backup script: nano /var/backup.sh Copy to Clipboard
# Backup MYSQL/MariaDB database to a sql file, then compress it
mysqldump -u root --databases mydatabase > /var/sqlbackup.sql ; gzip -f /var/sqlbackup.sql
#backup the folder /var (and all subdirectories)
rclone sync /var b2:foldername1/var
Set the new backup script to be executable chmod +x /var/backup.sh Open up crontab to schedule the backup: sudo crontab -e Set the time your backup should run. The following will run at 5 minutes after the hour, every hour. This site can help you schedule: https://crontab.guru/#15_*_*_*_* 05 * * * * . /var/backup.sh |