9 ms·
Timeshift: System Restore Tool for Linux
- tracker1 2y agoI've just got a simple script that uses rclone for most of my home directory to my NAS. For nearly everything else, I don't mind if I have to start mostly from scratch.
- yuumei 2y agoHas the btrfs sub volume quota bug been fixed yet? I always had issues when using it
- sschueller 2y agoI don't know but synology uses BTRFS now as well and if something crucial like that was broken I don't think they would support it on a NAS.
- marcus0x62 2y agoSynology uses custom extensions to BTRFS for much of their functionality.
- phoe-krk 2y agoI'd like some sort of a comparison with Duplicity/Déjà Dup that seems to be the default on Gnome/Cinnamon.
- fallingsquirrel 2y agoDifferent categories of app. Duplicity is geared toward backing up files to a separate machine, and this tool snapshots your filesystem on the same machine.
- phoe-krk 2y agoOK, thanks. I was confused because Time Machine is capable of backing up to a remote device.
- mkesper 2y agoIs that usable nowadays? Last time I checked it was hellishly slow compared to borg.
- phoe-krk 2y agoUsable enough for me. I don't mind since it's running in the background anyway.
- metadat 2y agoCan timeshift work with ext4 filesystems? I know it won't have the atomicity of a CoW fs, but I'd be fine with that, as the important files on my systems aren't often modified, especially during a backup - I'd configure it to disable the systemd timers while the backup process is running.
- gballan 2y agoJust getting started with it--but I think so, using rsync.
- mbreese 2y agoCan’t you also snapshot LVM volumes directly? So if you have an LVM volume, it shouldn’t matter what the filesystem is, provided it is sync’d… in theory. (I’ve only done this on VMs that could be paused before the snapshot, so YMMV.)
- nijave 2y agoYeah, you can take live snapshots with LVM. You can use wyng-backup to incrementally take and back them up somewhere outside LVM. This has been working pretty well for me to backup libvirt domains backed by LVs
- tamimio 2y agoYep, been using it for a while, incl ext4, you can have scheduled snapshots too, saved my arse few times, especially when you install something that cannot be easily uninstalled like hyperland or similar.
- tombert 2y agoThis reminds me of the default behavior of NixOS. Whenever you make a change in the configuration for NixOS and rebuild it, it takes a snapshot of the system configurations and lets you restore after a reboot if you screw something up. Similarly, it doesn't do anything in regards to user files.
- choward 2y agoI can't tell you the number of times I see a project and think to myself "NixOS already solves that problem but better."
- fallingsquirrel 2y agoIn fairness, this app supports snapshotting your home directory as well, and that's not solvable with Nix alone. In fact, I'm running NixOS and I've been meaning to set up Timeshift or Snapper for my homedir, but alas, I haven't found the time.
- __MatrixMan__ 2y agoIs there something about your home directory that you'd want to back up that is not covered by invoking home manager as a nix module as part if nixos-rebuild? https://nix-community.github.io/home-manager/index.xhtml#sec-install-nixos-module https://nix-community.github.io/home-manager/index.xhtml#sec... To me, it's better than a filesystem-backup because the things that make it into home manager tend to be exactly the things that I want to back up. The rest of it (e.g. screenshots, downloads) aren't something I'd want in a backup scheme anyhow.
- fallingsquirrel 2y agoI want to keep snapshots of my work. I run nightly backups which have come in handy numerous times, but accessing the cloud storage is always slow, and sometimes I've even paid a few cents in bandwidth to download my own files. It would be a lot smoother if everything was local and I could grep through /.snapshots/<date>/<project>.
- exe34 2y agooh this brings back memories, i found a script that did this about 15 years ago. it kept three versions of backups using rsync and hard-links to avoid duplication.
- dmitrygr 2y ago> similar to the System Restore feature in Windows and the Time Machine tool in Mac OS This makes no sense! System Restore is a useless wart that just wastes time making "restore points" at every app/driver install and can rarely (if ever) produce a working system when used to "restore" anything. It does not back up user data at all. Time Machine is a whole-system backup solution that seems to work quite well and does back up user data. To me the quoted statement might as well read "a tool similar to knitting needles (in hobby shops) and dremels (in machine shops)" Reading their description further, it seems like they are implementing something similar to TimeMachine (within the confines of what linux makes possible), and not at all like "System Restore". This seems sane as this implements something that is actually useful. They, sadly, seem to gloss over what the consequences are of using non-btrfs FS with this tool, only mentioning that btrfs is needed for byte-exact snapshots. They do not mention what sort of byte-inexactness ext4 users should expect...
- nijave 2y agoI believe System Restore takes a registry backup and can recover from a bad driver install but it's been years since I used it last. I think just about anything System Restore does can be replicated by "just fixing it" in Safe Mode but I think System Restore is geared for less technical folks. Newer versions of Windows have File History to backup user data (I don't think they have an integrated system/file solution quite like Time Machine though). However it makes some sense to keep system/user data separate. You don't want to lose your doc edits because you happened to have a bad driver upgrade at the same time. Likewise, you don't want to roll your entire system back to get an old version of a doc. Time Machine is trivial to implement (without the UI) with disk snapshots (that's what it does--store disk snapshots to an external disk)
- twodave 2y agoMy main use of system restore was to return to a “clean” install + just the bare minimum installs I needed back when windows was more likely to atrophy over time. I agree it is mostly useless today.
- magicalhippo 2y agoThey're talking about the Volume Shadow Copy Service[1], which effectively provides snapshots[2] of the filesystem. Which files are part of a shadow copy is determined by the one creating a shadow copy, so it could include user data. You can view and access the files in a shadow copy using ShadowExplorer[3] if you don't have the pro versions. [1]: https://learn.microsoft.com/en-us/windows-server/storage/file-server/volume-shadow-copy-service https://learn.microsoft.com/en-us/windows-server/storage/fil... [2]: https://learn.microsoft.com/en-us/windows/win32/vss/the-vss-model https://learn.microsoft.com/en-us/windows/win32/vss/the-vss-... [3]: https://www.shadowexplorer.com/ https://www.shadowexplorer.com/
- throwaway984393 2y ago[dead]
- ThinkBeat 2y agoA bit of a side note and a bit of old man reveal, it would be nifty to have the backup system write the snapshots to cd/dvd/bluray disk. I remember working in a company that had a robot WORM system. It would grab a disc, it would be processed, take it out, place it among the archives. If a restore as needed the robot would find the backup, and read off the data. I never worked directly on the system, and I seem to remember there was a window that the system could keep track of (naturally) but older disks were stored off site somewhere for however long that window was. (Everything was replicated to a fully 100% duplicate system geographically highly separated from the production system.
- gballan 2y agoAFAIK timeshift can use any mount. I tried a USB stick, but it was too slow. Now I'm experimenting with a partition on a second drive.
- umvi 2y ago> Creates filesystem snapshots using rsync+hardlinks Sounds like it works similarly to git fork on GitHub? That is, if no files have changed, the snapshot doesn't take up any extra room?
- deleted 2y ago[deleted]
- Izkata 2y agoDirectories and hardlinks take up space, just very little. It would make sense to hardlink a directory if everything in that tree was unchanged, but no filesystem will allow hardlinking a directory due to the risk of creating a loop (hardlinking to a parent directory), so directories are always created new and all files in the tree get their own hardlink. Apple's Time Machine was given an exception in their filesystem to allow it, since they have control over it and can ensure no such loops are created. So it doesn't have that penalty creating hardlinks for every single individual file every time.
- nurettin 2y agoTimeshift saved my system so many times over the past 6-7 years. Botched upgrades, experimenting with desktop environments, destroying configuration defaults, it works and does what it says on the tin.
- tamimio 2y agoCan’t agree more with this, it does what it says!
- prmoustache 2y agoHow can you "botch" upgrades so many times? I may have had only one update that went wrong in 30 years of using Linux and that was just a bug introduced by a gfx driver in a new minor kernel version. I downgraded it and waited for the bug to be fixed upstream and that was it.
- nurettin 2y agobravo, I guess?
- prmoustache 2y agoThat is not on me but the distro maintainers. They do a really good job imho and it appart from kernel drivers issue or hardware failure (drive) it is hard to break a distrib.
- e12e 2y agoHmm, this doesn't appear to be what I hoped it was: > Timeshift is similar to applications like rsnapshot, BackInTime and TimeVault but with different goals. It is designed to protect only system files and settings. User files such as documents, pictures and music are excluded. On the other hand, a quick search looking for "that zfs based time machine thing" did reveal a new (to me) project that looks very interesting: https://github.com/kimono-koans/httm https://github.com/kimono-koans/httm
- tamimio 2y agoYou can include the user files too in the home directory. I have some snapshots that include them and some that do not, so you are covered both ways.
- OldMatey 2y agoI adore Timeshift. It has made my time on Linux so much more trouble free. I have used Linux for 10+ years but over the I have spent hours, days and weeks trying to undo or fix little issues I introduce by tinkering around with things. Often I seem to break things at the worst times, right as I am starting to work on some new project or something that is time sensitive. Now, I can just roll back to an earlier stable version if I don't want to spend the time right then on troubleshooting. I've enabled this on all my family members machines and teach them to just roll back when Linux goes funky.
- pmarreck 2y agoWhile it's not quite average-user-friendly (YET), one of the reasons I switched to NixOS is because it provides this out-of-the-box. I was frustrated with every other Linux for the reasons you cite, but NixOS I can deal with, since 1) screwing up the integrity of a system install is hard to begin with, 2) if you DO manage to do it, you can reboot into any of N previous system updates (where you set N). Linux is simultaneously the most configurable and the most brittle OS IMHO. NixOS takes away all the brittleness and leaves all the configurability, with the caveat that you have to declaratively configure it using the Nix DSL.
- gooseyman 2y agoI enabled this four months ago and I have had the same experience. It’s not that I couldn’t retype the config file I accidentally wrote over while tinkering, but I like the safety that comes with Timeshift to try and fail a few times. Hard lessons come hard. This softens those lessons a little while maintaining the learning.
- LorenDB 2y agoI prefer using openSUSE, which is tightly integrated with snapper[0], making it simple to recover from a botched update. I've only ever had to use it when an update broke my graphics drivers, but when you need it, it's invaluable. Snapper on openSUSE is integrated with both zypper (package manager) and YaST (system configuration tool) [1], so you get automatic snapshots before and after destructive actions. Also, openSUSE defaults to btrfs, so the snapshots are filesystem-native. [0]: http://snapper.io/ http://snapper.io/ [1]: https://en.opensuse.org/Portal:Snapper https://en.opensuse.org/Portal:Snapper
- abbbi 2y agofor RHEL based distributions you can do the same with an LVM and using boom boot manager. https://github.com/snapshotmanager/boom-boot https://github.com/snapshotmanager/boom-boot
- Arnavion 2y agoAnd it's also integrated into the bootloader (if you use one of the supported ones). The bootloader shows you one boot entry per snapshot so you can boot an old snapshot directly.
- jwrallie 2y agoVery nice, sometimes people claim that the only difference between distros is the repository and package management tools. It is when the defaults make the parts integrate nicely like this that the “greater is more than the sum of its parts” come into place.
- Spunkie 2y agoThis is a feature I've really been missing since switching from grub to systemd-boot. Has anyone figured out an easy way to get this back with systemd-boot?
- Arnavion 2y agoSome time ago they did add systemd-boot as a supported option and apparently it also generates one entry per snapshot. https://news.opensuse.org/2024/03/05/systemd-boot-integration-in-os/ https://news.opensuse.org/2024/03/05/systemd-boot-integratio... https://en.opensuse.org/Systemd-boot#Installation_with_full_BTRFS_snapshot_and_secure_boot_support https://en.opensuse.org/Systemd-boot#Installation_with_full_... https://github.com/openSUSE/sdbootutil https://github.com/openSUSE/sdbootutil I haven't tried it though so I don't know for sure. (I have my own custom systemd-boot setup that predates theirs, and since my setup uses signed UKIs and theirs doesn't, I don't care to switch to theirs. I can still switch snapshots manually with `btrfs subvol` anyway; it just might require a live CD in case the default snapshot doesn't boot.)
- pixelmonkey 2y agoI've probably spent way too much time thinking about Linux backup over the years. But thankfully, I found a setup that works really well for me in 2018 or so, used it for the last few years, and I wrote up a detailed blog post about it just a month ago: https://amontalenti.com/2024/06/19/backups-restic-rclone https://amontalenti.com/2024/06/19/backups-restic-rclone The tools I use on Linux for backup are restic + rclone, storing my restic repo on a speedy USB3 SSD. For offsite, I use rclone to incrementally upload the entire restic repository to Backblaze B2. The net effect: I have something akin to Time Machine (macOS) or Arq (macOS + Windows), but on my Linux laptop, without needing to use ZFS or btrfs everywhere. Using restic + some shell scripting, I get full support for de-duplicated, encrypted, snapshot-based backups across all my "simpler" source filesystems. Namely: across ext4, exFAT, and (occasionally) FAT32, which is where my data is usually stored. And pushing the whole restic repo offsite to cloud storage via rclone + Backblaze completes the "3-2-1" setup straightforwardly.
- tlavoie 2y agoOne question, why use rclone for the Backblaze B2 part? I use restic as well, configured with autorestic. One command backs up to the local SSD, local NAS, and B2.
- pixelmonkey 2y agoI explain in the post. Here's a copypasta of the relevant paragraph: "My reasoning for splitting these two processes — restic backup and rclone sync — is that I run the local restic backup procedure more frequently than my offsite rclone sync cloud upload. So I’m OK with them being separate processes, and, what’s more, rclone offers a different set of handy options for either optimizing (or intentionally throttling) the cloud-based uploads to Backblaze B2."
- tlavoie 2y agoSo you did! Sorry, hadn't read the post beforehand. Oh, and I too mourned the loss of CrashPlan. Being in Canada, I didn't have the option offered to have a restore drive sent if needed, but thought it was a brilliant idea. On the other hand, I think Backblaze might!
- jenscow 2y agoI use BackInTime, which works in a similar way but is much more configurable. I have hourly backups of all my code for the past day, then a single daily for the past week, etc. Saved my ass a few times.
- Springtime 2y agoSounds like rsnapshot (rsync with hardlinks and scheduling) but the BackInTime repo doesn't mention any comparison of how it's different, though Timeshift says they're similar. Anyone have experience with BiT vs rsnapshot?
- bayindirh 2y agoBackInTime works similar to Apple TimeMachine. It uses hardlinks + new files. Plus, it keeps settings for that backup inside the repository itself, so you can install the tool, show the folder, and start restoring. On top of that BiT supports network backups and multiple profiles. I'm using it on my desktop systems with multiple profiles for years and it's very reliable. However it's a GUI first application, so for server applications Borg is a much better choice.
- raudette 2y agoI've used BackInTime since 2010. I loved that, even without using the tool, you could just poke through the file structure, and get an old version of any backed up file.
- gchamonlive 2y agoI use a series of scripts to make daily Borg backups to a local repository: https://github.com/gchamon/borg-automated-backups https://github.com/gchamon/borg-automated-backups Currently the local folder is a samba mount so it's off-site. The only tip I'd have for people using Borg is to verify your backups frequently. It can get corrupted without much warning. Also if you want quick and somewhat easy monitoring of backups being created you can use webmin to watch for the modifications in the backup folder and send an email if there isn't a backup being sent in a while. Similarly, you can regularly scan the Borg repo and send email in case of failures for manual investigation. This is low tech, at least lower tech than elastic stack or promstack, but it gets the job done.
- khimaros 2y agoi've had positive experience with borgmatic which is available in debian repos.
- gchamonlive 2y agoNeat! I'll take a look, thanks!
- pmarreck 2y agoYet another solution that is wholly unnecessary in NixOS. Nice idea, though, since you can too easily screw up every other Linux.
- Lord_Zero 2y agoI just switched from windows to Mint and the first thing it asked me was to configure backups and snapshots and stuff. Pretty cool!
- Groxx 2y agoMint's first-launch welcome-list is excellent. It's a relatively small thing but it helps a lot.
- wetpaws 2y ago[dead]
- stevefan1999 2y agoCan someone recommend a solution that works well with immutable distros such as Project Bluefin or Fedora Kinoite/Silverblue? We just need to backup maybe the etc and dotfiles. Also great if it can backup NixOS too.
- trinsic2 2y agoDon't forget Atpik. great for migrating a system to a new distro.
- sieve 2y agoZFS Snapshots + Sanoid and Syncoid to manage and trigger them is what people should be doing. Unfortunately, booting from ZFS volumes seems to be some form of black art unless things have changed over the last couple of years. The license conflict and OpenZFS always having to chase kernel releases often resulting in delayed releases for new kernels means I cannot confidently use them with rolling release distros on the boot drive. If I muck something up, the data drives will be offline for a few minutes till I fix the problem. Doing the same with the boot drive is pain I can live without.
- rabf 2y agoBest option to date: https://github.com/zbm-dev/zfsbootmenu https://github.com/zbm-dev/zfsbootmenu A shame most distro's installers don't support it natively, but an encrypted rootfs on ZFS is great once you get it setup.
- sieve 2y agoYeah. I am somewhat wary of trying this, mucking something up and wasting a lot of time wrestling with it. Will probably play around with it in a vm and use it during the next ssd upgrade. Would have been so much better if the distros showed more interest in ZFS
- aeadio 2y agoIn principle there's no reason you can't install this next to GRUB in case you're wary. If you're not using ZFS native encryption, and make sure not to enable some newer zpool features, GRUB booting should work for ZFS-on-root. That said, I've been using the tool for a while now and it's been really rock solid. And once you have it installed and working, you don't really have to touch it again, until some hypothetical time when a new backward-incompatible zpool feature gets added that you want to use, and you need a newer ZFSBootMenu build to support it. Because it's just an upstream Linux kernel with the OpenZFS kmod, and a small dracut module to import the pool and display a TUI menu, it's mechanically very simple, and relying on core ZFS support in the Linux kernel module and userspace that's already pretty battle tested. After seeing people in IRC try to diagnose recent GRUB issues with very vanilla setups (like ext4 on LVM), I'm becoming more and more convinced that the general approach used by ZFSBootMenu is the way to go for modern EFI booting. Why maintain a completely separate implementation of all the filesystems, volume managers, disk encryption technologies, when a high quality reference implementation already exists in the kernel? The kernel knows how to boot itself, unlock and mount pretty much any combination of filesystem and volume manager, and then kexec the kernel/initrd inside. The upsides to ZFSBootMenu, OTOH, * Supports all ZFS features from the most recent OpenZFS versions, since it uses the OpenZFS kmod * Select boot environment (and change the default boot environment) right from the boot loader menu * Select specific kernels within each boot environment (and change the default kernel) * Edit kernel command line temporarily * Roll back boot environments to a previous snapshot * Rewind to a pool checkpoint * Create, destroy, promote and orphan boot environments * Diff boot environments to some previous snapshot to see all file changes * View pool health / status * Jump into a chroot of a boot environment * Get a recovery shell with a full suite of tools available including zfs and zpool, in addition to many helper scripts for managing your pool/datasets and getting things back into a working state before either relaunching the boot menu, or just directly booting into the selected dataset/kernel/initrd pair. * Even supports user mode SecureBoot signing -- you just need to pass the embedded dracut config the right parameters to produce a unified image, and sign it with your key of choice. No need to mess around with shim and separate kernel signing.
- croniev 2y agoTimeshift does not work for me because I encrypted my ssd, decrypt on boot, but linux sees every file twice, once encrypted and once decrypted, thinking that my storage is full, and thus timeshift refuses to make backups due to no storage. At least thats as far as I'm understanding it atm
- sulandor 2y ago> linux sees every file twice, once encrypted and once decrypted fixing this should prove profitable
- _f9cu 2y ago[dead]
- commercialnix 2y ago[flagged]
- Argonaut998 2y agoIt’s not really a ‘system restore tool’ it’s a fully fledged backup program like Veeam
- commercialnix 2y ago> a fully fledged backup program like Veeam mhmm...
- Argonaut998 2y agoWell the free one I use on Windows*
- kkfx 2y agoNice UI :-) Random notes/suggestions - rsync is not a snapthot tool, so while in most of the cases we can rsync a live volume issueless on a desktop it's not a good idea doing so - zfs support in 2024 is a must, btrfs honestly is the proof of how NOT to manage storage, like stratis - it seems not much a backup tool, witch is perfectly fine but since the target seems to be end users not too much IT literate it should be stated clear...
- ivanjermakov 2y agoMagical thing about timeshift is that you can use it straight from your live CD. It will find root, backups, and restore it together with a boot partition.
- Shorel 2y agoMy system is different and simpler: The root partition / and the home partition /home are different. There's a /home/etc/ folder with a very small set of configuration files I want to save, everything else is nuked on reinstall. When I do a reinstall, the root partition is formatted, the /home partition is not. This allows me to test different distros and not be tied to any particular distro or any particular backup tool, if I test a distro and I don't like it, then it is very easy to change it.
- ijustlovemath 2y ago/home/etc or ~/etc?
- birdiesanders 2y agoThose are equivalent.
- ijustlovemath 2y agoTry it for yourself: [ /home/etc = ~/etc ] || echo theyre different
- michaelmior 2y agoOn most systems, that is not the case. Typically a user's home directory is `/home/USERNAME` so `~/etc` would be `/home/USERNAME/etc`.
- execat 2y agoNo. ~etc is equivalent to /home/etc. ~/etc is the same as /home/<current user>/etc.
- Shorel 2y ago/home/etc It is a backup directory owned by root. The reason is that it sits in the partition that is preserved, and it is outside my user folder, because it is better organized that way.
- 2y ago
- 8organicbits 2y agoI've found Debian Stable to be extremely stable, especially in recent years, I honestly don't think about system restore as much as I worry about a drive crashing or a laptop getting stolen. I assumed Linux Mint LTS was similarly stable. Folks who have run into issues, what was the root cause?
- nubinetwork 2y agoIsn't timeshift what apple calls their snapshot/backup thingy?
- aaronmdjones 2y agoNo, that's Time Machine.
- crabbone 2y agoMy first "real" experience with Linux was with Wubi (Ubuntu packaged as a Windows program). I think it was based on Ubuntu version 6 or 8. I also tried to update it, when the graphical shell displayed a message saying that update is available. Of course, it bricked the system. I've switched from Ubuntu to Mint to Debian to Fedora to Arch to Manjaro for personal use and had to support a much wider variety of distributions professionally. My experience so far has been that upgrades inevitably damage the system. Most don't survive even a single upgrade. Arch-like systems survive several major package upgrades, but also start falling apart with time. Every few years enough problems accumulate that merit either a complete overhaul or just starting from scratch. With this lesson learned, I don't try to work with backups for my own systems. When the inevitable happens, I try to push forward to the next iteration, and if some things to be lost, then so be it. To complement this, I try to make the personal data as small and as simple to replicate and to modify moving forward as possible. I.e. I would rule against using filesystem snapshots in favor of storing the file contents. I wouldn't use symbolic links (in that kind of data) because they can either break or not be supported in the archive tool. I wouldn't rely on file ownership or permissions (god forbid ACLs!) Try to remove as much of a "formatting" information as possible... so I end up with either text files or images. This is not to discourage someone from building automated systems that can preserve much richer assembly of data. And for some data my approach would simply be impossible due to requirements. But, on a personal level... I think it's less of a software problem and more of a strategy about how not to accumulate data that's easy to lose.
- nuriodaci 2y agoThe highly awaited Linux Mint 22.0 release marks a very exciting chapter for one of the most popular Ubuntu-based distributions. This new version is not meant to be some kind of regular update; it's an LTS version with promises of updates and support all the way to 2029. Both experienced Linux users and newcomers will find a lot in this version worthy of attention to detail in changes and new features. Let's break down what's new and what makes this release stand out. https://www.geeksmatrix.com/2024/07/linux-mint-220-whats-new-in-this-lts.html https://www.geeksmatrix.com/2024/07/linux-mint-220-whats-new...