Backup Your Linux Set up With Timeshift

#Backup #Linux #Set up #Timeshift

Ubuntu Linux is my major OS of selection at dwelling. I exploit Ubuntu server to run most of my dwelling lab servers, and I exploit Ubuntu desktop as my major day-to-day OS. Ubuntu drops a brand new OS launch each six months, however that’s extra typically than I wish to improve the whole lot. So I exploit the Lengthy Time period Help (LTS) Ubuntu releases, which come out each two years. I like to remain on the most recent, so I improve each two years. Most instances issues go proper, however a number of instances they haven’t, and I often simply have to put in it from scratch. However, now I exploit Timeshift to again up my set up first, which permits me to revert again to a earlier set up. Right here’s a fast overview of Timeshift.

Timeshift Pinterest Pin

What’s Timeshift

Timeshift has a goal just like Home windows System Restore and macOS Time Machine. It runs on most flavors of Linux, together with my most popular distro, Ubuntu. It creates snapshots of your OS on the intervals you specify. Timeshift may restore your system to a backup. If you happen to make modifications (like software or OS upgrades) that don’t work correctly, you possibly can restore an older snapshot of your OS when issues did work correctly.

Timeshift Logo
Timeshift Emblem

With a view to preserve house, Timeshift creates differential backups. Which means it solely backs up variations from earlier backups. If information in earlier backups haven’t been modified, there’s no must again them up once more. Timeshift will know when to seize unchanged information from older backups and new modifications while you need to restore a snapshot.

Timeshift makes use of Rsync (or in case you are utilizing BTRFS, it might use that) which is a time-tested software for backups. I’ve been utilizing Rsync to again up my consumer information (photographs, movies, paperwork, and so on.). It doesn’t devour a lot reminiscence, disk, or CPU cycles and works quietly within the background.

Timeshift set up on Ubuntu 20.04/22.04

Putting in Timeshift on later variations of Ubuntu is simple as a result of it’s already included within the default system repo. So all you must do is sort:

sudo apt set up timeshift

Then you possibly can run it by discovering it in your software menu or just typing:

on the command line. Notice you’ll want to produce your sudo password for admin entry. Then you definately’ll step by the preliminary configuration.

Step 1: Choose snapshot sort

First, it’s going to ask you to decide on a snapshot sort. Until you’ve gotten set your system to run BTRFS, follow the default of Rsync.

Timeshift snapshot type

Step 2: Choose the snapshot location

Now it’s time to select the place you need to save your snapshots. Be sure that to decide on a disk that has sufficient room in your snapshots. For some, that is an exterior drive or an additional arduous drive linked to the machine. In case you are utilizing an exterior arduous drive, be certain it’s in a format that Linux helps. Distant storage areas aren’t supported.

Snapshot location for timeshift

Step 3: Set your snapshot schedule

Subsequent, you arrange your snapshot schedule. Select how typically you need to create snapshots and what number of of every sort of snapshot you need to create:

snapshot schedule for timeshift

Notice the setting “Cease cron emails for scheduled duties.” If don’t choose this and you’ve got mail configured in your machine, you’ll obtain an e mail each hour as a result of Timeshift checks its schedule each hour to find out whether or not or not it must create a snapshot. I’ve no real interest in hourly emails so chosen this feature.

Step 4: Embrace or exclude consumer dwelling directories

Timeshift is designed for system backups, not for backing up your property directories. So, by default, it excludes your property directories. You possibly can override this setting for those who like.

home Directory selection Timeshift wizard

Subsequent you see the setup wizard completion display and now you might be finished… or are you?

Timeshift Wizard completion screen

Put up-installation configuration

If you happen to’re like me, and you’ve got a number of disks mounted to your pc. I’ve many who I don’t need to be backed up as a part of the Timeshift backups. Fortunately, you possibly can arrange filters to incorporate and exclude information and directories. Run Timeshift once more and go to Settings->Filters and choose the precise information and folders you need to embody and exclude.

Backup Your Linux Set up With Timeshift 10

You possibly can go into these settings and alter any of the choices you set in the course of the preliminary setup (snapshot location, schedule, consumer directories, and so on.). You too can change the date format of your snapshots.

Utilizing Timeshift

Utilizing Timeshift is easy. More often than not you don’t must do something and it’ll simply do its factor within the background. Sometimes chances are you’ll need to take a guide snapshot off schedule, and you are able to do that simply from the Timeshift UI. Simply click on “Create” on the primary display. Under you possibly can see the snapshots I’ve created and the way they’re tagged. You too can see that I took snapshots earlier than and after I upgraded to Ubuntu 22.04.

Backup Your Linux Set up With Timeshift 11

The tags point out what sort of backup it’s:

  • O — On demand
  • B — Boot
  • H — Hourly
  • D — Day by day
  • W — Weekly
  • M — Month-to-month

Timeshift may also be used through the command line. Simply sort:

to be taught extra.

Remaining ideas

Timeshift provides me additional confidence after I’m making main modifications to my system, like when I’m upgrading to a brand new model of Ubuntu. It’s easy to make use of, and dependable, and you may set it and overlook it. Timeshift will be part of a great backup technique.

Are you utilizing Timeshift? Do you employ one thing else as an alternative? Let me know within the feedback or on Twitter.

Leave a Reply

Your email address will not be published. Required fields are marked *