Backup with restic
Scripts
Because restic can also handle variables, you can use the tool to regularly back up data using scripts. The scripts can then be executed as cron jobs on a time-controlled basis. Ideally, you should set an environment variable for the password entry and for the storage path.
The fact that the software can basically access all your data media and filesystems opens up the possibility of transferring data to a NAS system or to a server via SFTP, for example. If you have slow storage or narrow bandwidths, however, the backup speed is naturally significantly lower than backing up the local filesystem.
GUI
Restatic [2], a GUI for restic, has been under development for some time now. You will find the application programmed in Python on GitHub. As its underpinnings, the front end needs Python v3.6 or higher. Many distributions with long-term support come with even older Python versions, which you have to update beforehand in order to be able to install Restatic.
After setup, call the software at the prompt by entering restatic
. In the program window that then opens, you can access the individual functions using a clear-cut tab structure (Figure 3). You always need to follow the same order as for the command-line program. In addition, you can define profiles at the beginning using the Current Profile: field; this is particularly useful for larger infrastructures with heterogeneous databases.
Then define a repository for the backup. To do this, click the Repository field in the Repository tab and select one of the options. To let you integrate existing repositories, a separate dialog box appears; you can use this to connect to the archive in question. Restatic supports connections to remote servers.
In the same way, you can use the SSH Key: field to specify in a context-dependent manner whether to use an existing key or generate a new key. Then switch to the Sources tab where you specify the directories to be backed up. To do this, use the Add Folder button to add individual folders to a list view. In the two lower window segments, you can then define exclusion criteria for folders and files that you are not going to back up.
After pressing Start Backup (bottom left), Restatic runs the backup and displays a progress bar. You then need to click on the Refresh button in the Archives tab to see the backups in the repository. The Extract, Check, Mount, and Prune buttons let you work with the backups. In this dialog, you can specify how many old archives you want to keep for multiple backup files.
To run the backup automatically in the future, use the Schedule tab. When you get there, you can define, at the push of a button, how often Restatic should save data from the previously specified source folders to the active repository. This avoids the need to write a shell script or create a cron job for automatic backups. After pressing Apply, Restatic applies the data and activates your automatic backup actions (Figure 4).
Conclusions
Restic takes away users' reservations about the command line by consistently adhering to a simple syntax for each function. The backup tool is very appealing due to its fast action, and above all the default encryption, which means that there is nothing standing in the way of backups to the cloud. With automatic, time-controlled backups and the option of using local SFTP servers as storage media, the software is also suitable for larger infrastructures. The Restatic GUI also lets users create backups easily, in this case, at the push of a button.
Infos
- restic: https://restic.net
- Restatic: https://github.com/Mebus/restatic
« Previous 1 2
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
TUXEDO Computers Unveils Linux Laptop Featuring AMD Ryzen CPU
This latest release is the first laptop to include the new CPU from Ryzen and Linux preinstalled.
-
XZ Gets the All-Clear
The back door xz vulnerability has been officially reverted for Fedora 40 and versions 38 and 39 were never affected.
-
Canonical Collaborates with Qualcomm on New Venture
This new joint effort is geared toward bringing Ubuntu and Ubuntu Core to Qualcomm-powered devices.
-
Kodi 21.0 Open-Source Entertainment Hub Released
After a year of development, the award-winning Kodi cross-platform, media center software is now available with many new additions and improvements.
-
Linux Usage Increases in Two Key Areas
If market share is your thing, you'll be happy to know that Linux is on the rise in two areas that, if they keep climbing, could have serious meaning for Linux's future.
-
Vulnerability Discovered in xz Libraries
An urgent alert for Fedora 40 has been posted and users should pay attention.
-
Canonical Bumps LTS Support to 12 years
If you're worried that your Ubuntu LTS release won't be supported long enough to last, Canonical has a surprise for you in the form of 12 years of security coverage.
-
Fedora 40 Beta Released Soon
With the official release of Fedora 40 coming in April, it's almost time to download the beta and see what's new.
-
New Pentesting Distribution to Compete with Kali Linux
SnoopGod is now available for your testing needs
-
Juno Computers Launches Another Linux Laptop
If you're looking for a powerhouse laptop that runs Ubuntu, the Juno Computers Neptune 17 v6 should be on your radar.