I’d mentioned Duplicati in the “multiple backup” thread as a possible alternative backend for the backup system. It has a few handy features, some of which I’d mentioned in the other thread, but the biggest to me is the ability to very easily set up AES256-encrypted backups to a number of cloud storage providers through a pretty simple web UI. It’s pretty straightforward to install on Neth, too:
yum install yum-utils
rpm --import "http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF"
yum-config-manager --add-repo http://download.mono-project.com/repo/centos7/
yum install mono-devel libappindicator https://updates.duplicati.com/beta/duplicati-2.0.3.3-2.0.3.3_beta_20180402.noarch.rpm
echo "[Unit]
Description=Duplicati Backup software
[Service]
ExecStart=/usr/bin/mono /usr/lib/duplicati/Duplicati.Server.exe --webservice-interface=any
Restart=on-failure
RestartSec=30
[Install]
WantedBy=multi-user.target" > /etc/systemd/system/duplicati.service
systemctl enable --now duplicati
config set fw_duplicati service status enabled TCPPort 8200 access green
signal-event firewall-adjust
Then browse to http://yourIP:8200 for the Duplicati web UI. You can set a password there if you like.
Setting up a backup is easy. First click Add Backup from the menu:
Select Configure a new backup, then Next. On the next screen, give the backup a name (whatever you like), select the encryption type, and enter or generate a password/phrase:
On the next screen, enter your backup destination. Here, I’ll select Google Drive. Enter the path on your desired destination, then click on the blue AuthID link:
That will bring up the following window; click the blue button:
Enter your login credentials, and then you’ll be asked if you want to allow Duplicati access to your Google Drive account. Click the blue Allow button. A long AuthID will be generated, and will populate back into Duplicati’s Destination page. Click the blue Test Connection button. If the connection was successful, click Next to select what to back up.
Here you can select the source material from the tree, or just enter paths one at a time using the Add path button. Click Next when done.
The next page is the scheduler. Select when you want backups to run, then click Next.
On the next page, you’ll set options. The upload volume size and retention are self-explanatory. The Advanced Options allow you a lot of control over the backup job; one way you can use that is to signal events (say, signal-event pre-backup-data
before starting, and signal-event post-backup-data
on completion, use the run-script-before and run-script-after options, respectively).
Click Save, and your job will be saved.
After you’ve set up the job through the GUI, it will give you the option to export it as a command line. That will look kind of like this:
mono /usr/lib/duplicati/Duplicati.CommandLine.exe backup "googledrive://duplicati/phabricator/?authid=(redacted)" /var/repo/ /var/log/ /root/ /var/lib/nethserver/ /var/lib/collectd/ /var/www/html/ /usr/share/nextcloud/config/config.php --backup-name="Server backup" --dbpath=/root/.config/Duplicati/WBNGWVABWS.sqlite --encryption-module=aes --compression-module=zip --dblock-size=50mb --passphrase="(redacted)" --retention-policy="1W:1D,4W:1W,12M:1M" --run-script-before="signal-event pre-backup-data" --run-script-after="signal-event post-backup-data" --disable-module=console-password-input