Guide Servers + Cloud Computing LAMP, WAMP, Linux Servers, Embedded DietPi - Guide for Setup of features Setup B2 Backup using rclone in DietPi Updated October 08 2025
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
Search Keywords: robocopy, backup, clone, save, ssh, database




©2024 - Some portions of this website are Copyrighted.
Your IP: 216.73.216.83     Referring URL:
Browser: Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)
Terms and Conditions, Privacy Policy, and Security Policy