Backing up and restoring your system using Systemback
Snapshot

© Lead Image © scyther5, 123RF.com
At the push of a button, Systemback backs up or clones the complete current system and can restore it as required.
Windows provides extremely useful recovery points. At the push of a button, the operating system backs up the whole system in its current state. You can restore this backup later and thus return to the old state. This feature is particularly useful if newly installed software goes haywire or if you accidentally trash the configuration. Until now, such a function has been missing in Linux. To back up the system, you either had to use a backup program or had to back up the whole partition with a Live system, such as Clonezilla [1], which is fairly awkward.
The tool Systemback brings this recovery feature to Linux. Systemback backs up the current system and restore it as needed (see the "Warning" box). Systemback also offers the possibility of copying the current system, or one of the backups, to another data storage device; this is particularly useful if you want to migrate the system to a new computer.
Warning
When first using Systemback, try backing up and restoring on a test system. This way, you will know what steps you need to take in a worst-case scenario. The publisher and author assume no liability for incorrect operation or software errors.
As a bonus, Systemback creates a Live system on the computer that can be written to a USB flash drive or a DVD. Finally, the tool also handles updates and will try to repair a faulty system. Systemback has one small drawback, however: Currently it only runs on Debian "Jessie" and on Ubuntu and its derivatives, such as Linux Mint 17.
Launch Ramp
How you install Systemback depends on the particular distribution you are using. If you are running Ubuntu, or a distribution based on it, simply integrate a PPA and then install the systemback package from it (Listing 1).
Listing 1
Install Systemback
$ sudo add-apt-repository ppa:nemh/systemback $ sudo apt-get update $ sudo apt-get install systemback
You can download the latest version of Systemback from SourceForge in Debian "Jessie" [2]. When doing so, make sure to get the Systemback Install Pack, which SourceForge should offer to download by default. Unpack the archive on the hard drive and then, working as the root user, launch the install.sh
script, which will guide you through the software installation.
You can start Systemback either using the Dash or the Start menu, or by entering the command from Listing 2 in a terminal. Systemback requires system administrator or root rights at startup to work. The main window from Figure 1 then appears.
Listing 2
Start Systemback
$ /usr/lib/systemback/sbsustart systemback
Depository
Systemback stores backups in the /home
directory by default. To change this, click at the top right in the input field under Storage directory to the right of /home. Systemback can use the directories marked with a red bullet.
Systemback later creates the Systemback
directory, where the individual backups go, in the selected storage directory. Therefore, this directory must provide at least twice as much storage space as the system currently occupies. The command-line tool df -h
, for example, shows the corresponding value in the Used column.
Systemback merely backs up the system and configuration files from the user directories. Thus, you must look after data and documents yourself. Systemback understands all configuration files and subdirectories that begin with a dot, such as .config
.
You can exclude a specific configuration file or all configuration files from the backup by clicking Exclude in the main window. Now, in the list on the left-hand side of the new window, you can select the file or directory you do not want to back up then click on the right arrow (Figure 2). To remove any entries you might have chosen accidentally, click on the file then the left arrow. Pressing Back returns you to the main window.

Friendly Service
Click on Create new to create a new backup. The process may take a while depending on the system. Systemback will back up a freshly installed Ubuntu 14.10 in about 10 minutes. A new entry then appears in the main window on the left-hand side in one of the restore points. Systemback names the backup to reflect the current date. To rename it, simply click on the field, enter a descriptive name, and save the changes by clicking on Rename.
Systemback then only saves the files that are new or modified for future backups (see also the "Behind the Scenes" box). These incremental backups are advantageous because they take up less disk space. However, a faulty backup means that any subsequent backups cannot be restored either. For this reason, you should basically never delete directories manually or make changes in the selected Storage directory.
Behind the Scenes
Systemback first creates a new subdirectory for each backup in the specified Storage Directory (/home/Systemback
by default). The subdirectory names start with an S
and a number in sequence, followed by the creation date and time of backup. You can thus find the second backup (S02
) created by Systemback on December 22, 2014, at 5:41pm in the S02_2014-12-22,17.41.46
subdirectory. The directory names of "highlighted restore points" always start with H
. If you rename the backup in the main window, the directory name will change, too.
When creating the first backup, Systemback simply copies all system files into the corresponding directory (S01_
…). During the next backup, Systemback only backs up newly added files and those that have changed in the meantime in the appropriate directory (S02_
…). For the corresponding unchanged files of the previous backup, it simply creates references in the form of hard links [3]. If you view the backup directories with a file manager, a complete copy of the system appears to exist in each directory.
Systemback can manage up to 10 system backups. You will have to delete one or more backups if a new operation is to store the backup in the Restore points column. Check the box to the right of the backups that are to be deleted (Figure 3) and click Delete. All subsequent backups then move up one place.
In addition to this method, you can free up space in another way: If you click on the dot to the left of the backup, Systemback will highlight this and all newer backups in red (Figure 4). As soon as you click Create new, Systemback will delete the highlighted backups and immediately create a new one. Do not forget to select the next free field on the left-hand side. Otherwise, the next click on Create new would overwrite the current backup.
You can mark particularly important backups separately. Check the box to the right of the backups and click Highlight. This will move the backup to the middle column. Systemback labels the backups collected there as Highlighted restore points. They cannot be (accidentally) overwritten, but they can be deleted by pressing Delete. A backup promoted in this way cannot be downgraded again to a normal backup – so think carefully before clicking Highlight.
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Direct Download
Read full article as PDF:
Price $2.95
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Find SysAdmin Jobs
News
-
SparkyLinux 6.6 Now Available for Installation
The Debian-based SparkyLinux has a new point release that retools the live USB desktop creator and other changes that give it shiny new-ness.
-
SparkyLinux 6.6 Now Available for Installation
The Debian-based SparkyLinux has a new point release that retools the live USB desktop creator and other changes that give it shiny new-ness.
-
Escuelas Linux 8.0 Now Available
Just in time for its 25th anniversary, the developers of Escuelas Linux have released the latest version.
-
LibreOffice 7.5 Loaded with New Features and Improvements
The favorite office suite of the Linux community has a new release that includes some visual refreshing and new features across all modules.
-
The Next Major Release of Elementary OS Has Arrived
It's been over a year since the developers of elementary OS released version 6.1 (Jólnir) but they've finally made their latest release (Horus) available with a renewed focus on the user.
-
KDE Plasma 5.27 Beta Is Ready for Testing
The latest beta iteration of the KDE Plasma desktop is now available and includes some important additions and fixes.
-
Netrunner OS 23 Is Now Available
The latest version of this Linux distribution is now based on Debian Bullseye and is ready for installation and finally hits the KDE 5.20 branch of the desktop.
-
New Linux Distribution Built for Gamers
With a Gnome desktop that offers different layouts and a custom kernel, PikaOS is a great option for gamers of all types.
-
System76 Beefs Up Popular Pangolin Laptop
The darling of open-source-powered laptops and desktops will soon drop a new AMD Ryzen 7-powered version of their popular Pangolin laptop.
-
Nobara Project Is a Modified Version of Fedora with User-Friendly Fixes
If you're looking for a version of Fedora that includes third-party and proprietary packages, look no further than the Nobara Project.