What features did the rdiff-backup utility have thanks to migration to Python 3

During the migration to Python 3, the developers of the rdiff-backup utility have improved it, adding many new features.







In March 2020, the second major release of the rdiff-backup utility was released . The second - for 11 years. This is largely due to the end of support for Python 2. The developers decided to combine business with pleasure and improved the functionality of the utility.



For about 20 years she has been serving the Linux community with faith and truth - helping to make backups on local and remote machines, let's say ... without unnecessary headaches. The secret is simple: the utility allows you to backup only those files that have changed since the last backup. For a more concise definition of this process, there is the term "incremental backup".



Rdiff-backup was reborn thanks to a team of enthusiasts led by Erik Solf and Patrick Dufresne of IKUS Software and Otto Kekeläinen from Seravo .





New features



The project has moved to a new repository and invites everyone to become contributors. The team has made all the useful improvements that have appeared over the past 11 years into the new release. Among them - support for sparse files and bug fixes for hard links.



Automation based on Travis CI



Another major improvement is the CI / CD pipeline based on the Travis CI distributed web service . Users will now be able to run rdiff-backup in various test environments without the risk of breaking a running project. The CI / CD pipeline will enable automated assembly and delivery for all major platforms.



Easy installation with yum and apt



The new version works on most Linux operating systems - Fedora, Red Hat, Elementary, Debian and many others. The developers have tried to prepare all the necessary open repositories for easy access to the utility. You can install rdiff-backup using the package manager or the step-by-step instructions on the project's GitHub page.



New house



The project site has moved from Savannah to GitHub Pages ( rdiff-backup.net ), the developers have updated the content and design of the site.



How to work with rdiff-backup



If you are new to rdiff-backup, you will be surprised how easy it is to use. The developers made sure that you feel comfortable: in their opinion, such utilities should not distract with their complexity from such important processes as preparing a backup or planning data recovery.



Backup



To run a backup on a local drive (eg USB), enter the rdiff-backup command , then the source name (where you will copy the files from) and the path to the directory where you plan to save them.



For example, to make a backup to a local drive named my_backup_drive , enter:



$ rdiff-backup /home/tux/ /run/media/tux/my_backup_drive/


To save files to external storage, enter the path to the remote server along with the "::"



$ rdiff-backup /home/tux/ tux@example.com::/my_backup_drive/


You will probably also need SSH keys to access the server.



Restoring files from a backup



Backups are made because sometimes some files tend to be, shall we say ... lost. The utility allows you to simply restore files from a backup. But still, with the click of a finger, this will not work.



Here copy commands will come to our aid - cp for the local disk and scp for the remote server.



For a local disk, you need to write, for example, this:



$ cp /run/media/tux/my_backup_drive/Documents/example.txt ~/Documents


For a remote server:



$ scp tux@example.com::/my_backup_drive/Documents/example.txt ~/Documents


The rdiff-backup command has options that allow you to customize the backup options. For example, --restore-as-of allows you to specify which version of the file to restore.



Let's say you want to restore a file to the state it was in 4 days ago:



$ rdiff-backup --restore-as-of 4D /run/media/tux/foo.txt ~/foo_4D.txt


Or maybe you want the latest version:



$ rdiff-backup --restore-as-of now /run/media/tux/foo.txt ~/foo_4D.txt


You can see that rdiff-backup is easy enough to work with. This utility has many settings and capabilities. For example, you can exclude individual files from the backup list, make backups from one remote server to another, and so on. You can find a description of all its features on the documentation page .






Advertising



Our epic servers use only NVMe NAS with triple replication of data, reliability is at its best! You can use the server not only to host your projects and any information, but also to store backups of important data from local machines or other servers. In addition, it is possible to make backup copies of the virtual server image in automatic or manual mode.






All Articles