@akhil that explains it – although instead of
mv /mnt/subvol_root /mnt/subvol_root.broken
btrfs subvol snapshot /mnt/snapshots/X/snapshot /mnt/subvol_root
i could also do
btrfs subvol snapshot -r /mnt/@ /mnt/@ backup
fd -E /mnt/@/.snapshots /mnt/@ -x rm -rf
mv /mnt/@/.snapshots/^/snapshot/* /mnt/@/
the first is harder to mess up though, true.
I guess I should migrate :)
@tippfehlr
If you remove this line from /etc/grub.d/10_linux:
GRUB_CMDLINE_LINUX="rootflags=subvol=${rootsubvol} ${GRUB_CMDLINE_LINUX}"
re-run `grub-mkconfig -o /boot/grub/grub.cfg`, remove root's `subvol` option from the fstab, to allow the system boot from the default btrfs subvolume set by `btrfs subvolume set-default`, and then run:
snapper create
snapper --ambit classic rollback <snapshot id>
and reboot.
Then you can drop your @ subvolume and use snapper's rollback command to rollback the root.
Make sure you actually using snapshot as the live root before removing your @ subvolume. I had to repair my system with a bootable flash drive because I did not know about the subvol option in the grub config.
@tippfehlr
If you remove this line from /etc/grub.d/10_linux:
GRUB_CMDLINE_LINUX="rootflags=subvol=${rootsubvol} ${GRUB_CMDLINE_LINUX}"
re-run `grub-mkconfig -o /boot/grub/grub.cfg`, remove root's `subvol` option from the fstab, to allow the system boot from the default btrfs subvolume set by `btrfs subvolume set-default`, and then run:
snapper create
snapper --ambit classic rollback <snapshot id>
and reboot.