btrfs rollback (how to)

I wanna ask simple question I’ve some trouble booting… I solved it but I also tried do a rollback, I was in text mode and I did

btrfs subvolume set-default xxx /.snapshots 

xxx - the id of the snapshot (working state)

(or in chroot live CD it could be

... set-default xxx /mnt./snapshots 

if you’ve mounted your system in /mnt of that liveCD session), but I did a lot of changes to system that day so I don’t clearly know which snaphsot it should be even if I use

snapper list 

. So my questions is was my method/command right cause I’ve only found posts like this which was about apt-btrfs-snapshot package but I just if you build from source or change some settings , config files you may want to set any snaphsot you know is good (fully working system as it was before changes) as default
Or use smth like this

snapper -v undochange 2..3
  • that undo change between snapshot with ID 2-3 but like if I want to undo change between 2-10 it’d be
snapper -v undochange 2..10

or if you want to undochange on particular dir

snapper -v undochange 2..3 /etc/sysconfig/*

With the default subvolume layout created during installation snapshots cannot be used directly because far too many directories will be missing. I know that there is some work in progress to allow it, but as far as I understood this is not intended as permanent rollback to previous version but rather as possibility to boot into previous snapshot for short term.

So I guess using snapshots as backup is the only way (i.e. - yuo have old versions of files so you can fetch them from snapshot to replace files in your real filesystem).

If you use Yast (also available in textmode), it may be a bit easier. Use the snapper module, have a look.

I don’t have the snapper snapper module in yast nad I wonder why. And I understand so far that snapper only undo zypper and yast changes by this official guides

I was assuming you’re running 13.1, in the renewed Yast there is a snapper module.

As there was in 12.3 (and 12.2 possibly).