BTRFS snapshots and grub-btrfs/snapper behaviour #58
Replies: 3 comments 10 replies
-
Hi there, thanks a lot for writing. I'm really glad to hear you find the projects useful. Regarding the first question, when booted into a read-only snapshot it does show which one is booted with the
After performing
This correctly mounts the restored system because the snapper-rollback script simply renames the old (let's imagine it's broken)
Compare this with the initial SpiralLinux installation before snapshots or rollbacks:
This is all quite different from what GeckoLinux does (following the same basic principles of vanilla openSUSE):
And then after booting RO snapshot 4 in GeckoLinux, then
So as you can see, the openSUSE GRUB configuration makes it boot the snapshot that was selected for rollback directly from the
So basically, SpiralLinux uses Snapper because it's the best solution for automated snapshots with automatic cleanup and integration with
That definitely won't be possible for SpiralLinux, because a major goal of the project is to not fork or recompile any Debian packages, so we're stuck with whatever Snapper package Debian chooses to ship. But I'm not concerned about that, because first of all Snapper's native Regarding the second question, you're seeing the expected behavior, because immediately after the rollback it also reverts to the previous contents of The issue that you found that I reported was different; the problem there was that even after rebooting into the restored system and trying to update the GRUB menus it would find the new snapshots and add them to the correct files in Hope this helps! |
Beta Was this translation helpful? Give feedback.
-
I currently have a system running Debian with encrypted btrfs and @ and @home subvolumes, but I have always wanted to replicate OpenSUSE's easy btrfs rollback feature. Later on I find out about the awesome Spiral Linux project which basically has exactly what I'm looking for. At the same time, I don't want to go through the effort of reinstalling and I don't find much use for any of Spiral Linux's other additions. So, does anyone know how I can get this functionality on a regular Debian system? I've tried to think about how to implement but there are a lot of moving parts and I am not sure where to start. Any advice? |
Beta Was this translation helpful? Give feedback.
-
I went to post asking why rolling back with snapper was not working like openSUSE and found this page via search. This really needs pinned or a brief explanation on a welcome window for new users since it does not align with all the common snapper syntax we find online. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi
Awesome job at creating Spiral Linux. In the past I had looked inside the tar archives of Gecko Linux and borrowed configs I wanted to import into my openSUSE TW install and I'm cheekily doing this again with Spiral Linux now that I have moved from openSUSE to Debian Testing. (your work is very much appreciated!)
Specifically, I was interested in how you managed to get snapper / grub-btrfs working in Debian. I don't think anyone appreciates how convuluted it all is. You should have blogged about your trials / tribulations when creating Spiral Linux as it would have been interesting reading.
I understand that by installing snapper, you are only making use of its functionality to create/delete/list/diff/manage snapshots. i.e. you are not using its rollback functionality. That job is done by snapper-rollback.
Full system rollback via grub is an important feature to me since with Debian Testing, I can expect that at times, I might break the system with an apt upgrade.
So I've been testing how snapper/grub-btrfs and snapper-rollback work in a Spiral Linux KDE Plasma VM in order to borrow the config and apply to my Debian Testing install.
In Spiral Linux, when creating snapshots (by installing pkgs via apt-get) and performing a snapper-rollback, I noticed that there was no way to find out which snapshot id is active after the reboot.
Running
snapper ls
does not show a star (*) next to the snapshot id in the table. e.g. output from openSUSE:In Spiral Linux, what I see is:
Query 1: Is it possible to figure which snapshot is the default or is active ? The output of
btrfs subvolume list -ta /
orcat /proc/mounts
orbtrfs subvolume get-default /
don't seem to help answer this (unless I'm overlooking something). Update: I came across this PR which indicates that snapper can be compiled with ano-rollback
compile option and was wondering if that is what needs to happen in this case when we aren't planning to use snapper's rollback functionality. You can find what compile options are set viasnapper debug
.I saw the Github issues you raised in snapper-rollback and grub-btrfs. I was likewise testing what snapshots are visible once a system rollback is done and it seems I can only see the snapshots created before the snapshot id I rolled back too in grub. For example, in the above
snapper ls
output, I did asnapper-rollback 5
and the only snapshots I could see in grub were: 4, 3, 2 and 1.Query 2: Should I be able to see snapshots 5 and 6 in grub ? I ask since they are visible and present in
snapper ls
output. In openSUSE for example, I am able to see all the snapshots except the one that is the active one.regards,
JC
Beta Was this translation helpful? Give feedback.
All reactions