On 2019-07-05 7:06 a.m., Ulli Horlacher wrote: > > Ok, it seems my idea (replacing the original root subvolume with a > snapshot) is not possible. >
Disclaimer: You probably want to wait at least 24 hours before trying my directions in case anyone has am important correction to make. You should have a means of recovering in case I got it completely wrong. (ie. good backups) It is common practice with installers now to mount your root and home on a subvolume for exactly this reason. (And you can convert your current system as well. Boot your system with a removable boot media of your choice, create a subvolume named @. Move all existing folders into this new subvolume. Edit the @/boot/grub/grub.cfg file so your Linux boot menu has the @ added to the paths of Linux root and initrd. Ex: linux /@/boot/vmlinuz-4.15.0-43-generic root=UUID=78d04a41-3786-4140-aeb8-5f2f809e7ba7 initrd /@/boot/initrd.img-4.15.0-43-generic (you can make this change directly into the grub menu at boot time instead of editing the grub.cfg file, if you prefer.) Edit the @/etc/fstab file so that mount points to the device we are changing have the subvol=@ option. Example: UUID=78d04a41-3786-4140-aeb8-5f2f809e7ba7 / btrfs noatime,nossd,subvol=@ 0 1 Reboot, and if the system successfully boots, you should run update-grub to fix up the grub.cfg file. From a running system, if you need to see the root subvolume again, (so you can see and manipulate the @ subvol,), mount it somewhere else: mkdir /mnt/sda1 mount /dev/sda1 /mnt/sda1 From that point forward, it's easy to rename /mnt/sda1/@ and replace it with a snapshot of your choice,. (then reboot.)
signature.asc
Description: OpenPGP digital signature