How to back up directly to Google Drive on Linux
Did you know that you can back up your Linux files directly to Google Drive? It’s true! The Duplicati application makes sending your important Linux files to Google Drive incredibly easy. Here’s how to do it on your Linux system.
Installing Duplicati on Linux
Duplicati is available for all major Linux distributions via downloadable packages. Officially, they support Debian, Ubuntu, Fedora, and OpenSUSE. It is also possible to get it working on Arch Linux via the AUR.
To install Duplicati on your Linux computer, start by opening up a terminal window. You can open a terminal window by pressing Ctrl + Alt + T on the keyboard. Or, search for “Terminal” in the app menu and launch it that way too.
With the terminal window open and ready to use, follow the installation instructions below that correspond with the Linux OS on which you plan to run Duplicati backups.
Ubuntu — installation instructions
To set up Duplicati on Ubuntu, start downloading the Duplicati DEB package to your system. You can use the wget command below to grab the package.
wget https://updates.duplicati.com/beta/duplicati_2.0.6.3-1_all.deb
Once the package is downloaded to your Ubuntu system, you can install it using the following apt install command. This command will set up the program and configure all required dependencies.
sudo apt install ./duplicati_2.0.6.3-1_all.deb
Those using Ubuntu 22.04 LTS will need to download the following package to fix errors with Duplicati.
wget http://debian.mirror.ac.za/debian/pool/main/o/openssl/libssl1.1_1.1.1o-1_amd64.deb sudo apt install ./libssl1.1_1.1.1o-1_amd64.deb
Debian — installation instructions
Duplicati supports Debian. To get it working on your computer, you must first download the latest release of Duplicati for Debian. Use the following wget download command below to grab it.
wget https://updates.duplicati.com/beta/duplicati_2.0.6.3-1_all.deb
Once the Duplicati DEB package is downloaded to your computer, you can use the dpkg command to install the software to your computer.
sudo dpkg -i duplicati_2.0.6.3-1_all.deb
With the Duplicati package installed on your Debian Linux system, you must run the apt-get install -f command to correct any dependency issues during installation.
sudo apt-get install -f
If you run into errors with Duplicati, there is a fix. Download and install the SSL package mentioned in the Ubuntu section.
Arch Linux — installation instructions
If you use Arch Linux, it is possible to install Duplicati using the AUR. This package is unofficial. However, it works just fine. To install the software, you must first install the Trizen AUR program. Use the commands below to get Trizen working.
sudo pacman -S git base-devel git clone https://aur.archlinux.org/trizen.git cd trizen/ makepkg -sri
Now that the Trizen AUR helper tool is up and running on Arch Linux, use the trizen -S command to install the latest release of Duplicati.
trizen -S duplicati-latest
Fedora — installation instructions
Those on Fedora Linux can get the latest version of Duplicati working by downloading the official RPM package from the website using the wget download command below.
wget https://updates.duplicati.com/beta/duplicati-2.0.6.3-2.0.6.3_beta_20210617.noarch.rpm
With the RPM package downloaded to your computer, you can install it using the following dnf install command.
sudo dnf install duplicati-2.0.6.3-2.0.6.3_beta_20210617.noarch.rpm
OpenSUSE — installation instructions
On OpenSUSE, Duplicati can be installed. However, you must first download the official RPM package to your computer. Using the following wget download command, grab Duplicati.
wget https://updates.duplicati.com/beta/duplicati-2.0.6.3-2.0.6.3_beta_20210617.noarch.rpm
With the package downloaded to your computer, you can use the zypper install command below. This will set up Duplicati on OpenSUSE.
sudo zypper install duplicati-2.0.6.3-2.0.6.3_beta_20210617.noarch.rpm
How to create a backup to Google Drive with Duplicati
Follow the steps below to back your files to Google Drive with the Duplicati application.
- Launch the Duplicati app by clicking on the shortcut icon in your panel taskbar. When you select the icon, Duplicati will open up in the default web browser.
- Find the “Add backup” button in the Duplicati sidebar and click on it with the mouse. Then, select the “Configure a new backup” button, followed by “Next.”
- Find the “Name” text box, and type in the name of the backup. Then, find “Description” and write the backup’s description.
- Find the “Passphrase” box, and write to encrypt the backup in your passphrase. Then, enter it a second time in the “Repeat Passphrase” box. Alternatively, select the Generate button to generate a secure encryption password.
- Find the “Storage Type” section and change it from “Local folder or drive” to “Google Drive.” You’ll then need to enter the folder you wish for it to save to on your Google Drive account. Alternatively, leave it blank to allow it to upload to the root Drive folder.
- Click on the “AuthID” button. Duplicati will connect to your Google Drive account when you select this button. Then, when the AuthID is generated, click on the “Test connection” button. Finally, click the “Next” button to continue.
- You must now select your “source data.” This is the data that you wish to upload to Google Drive. Use the web browser file manager under “Source data” to select the folder you want to upload to the Google Drive service. Click “Next” to continue.
- Following selecting your source data, you’ll need to decide if you wish to schedule backups for Duplicati to Google Drive. If you want to schedule it, check “Automatically run backups” and configure your schedule. Otherwise, uncheck the box.
- After configuring the schedule, set how large you wish the backup volume archives to be by configuring the settings in the General options, otherwise, leave it as default and click the “Save” button to move to the next page.
- Once everything is configured, find the “Run now” button to begin the backup process.
How to restore your backups
To restore a backup with Duplicati hosted on your Google Drive account, click the “Restore” button. Then, select your backup in the list. Click the “Next” button to begin the restoration process. You’ll then be asked what to restore and where to restore it. When you’ve selected both options, click on the “Restore” button.
Great article, specially the section for OpenSuse.