How to set up backup and synchronization of user data and configurations in Linux distributions using the Timeshift utility and package manager?
Maintaining the stability of a Linux operating system often requires creating system snapshots before performing major updates or software experiments. The Timeshift utility is created specifically for these purposes and allows rolling back the system state to a stable point without losing personal user files.
Timeshift installation is performed from the standard repositories of most distributions. When launching the utility for the first time, you need to select the snapshot type: BTRFS or RSYNC. If your root partition is formatted in the BTRFS file system, it is recommended to choose this type, as snapshots are created instantly and take up virtually no additional disk space. Otherwise, the RSYNC mode based on hard links is used.
After selecting the snapshot type, configure the schedule for automatic backup creation. You can specify the retention of monthly, weekly, daily, or even hourly operating system snapshots. It is important to note that by default, Timeshift excludes user home directories from snapshots, focusing exclusively on system files and configurations.
To synchronize and back up personal user data from the home directory, you should use additional tools such as Deja Dup or BorgBackup. In addition, a good practice is to export the list of installed system packages to a text file using the package manager to be able to quickly restore software on new hardware.