grub-btrfs icon indicating copy to clipboard operation
grub-btrfs copied to clipboard

Unable to restore or delete files after running snapshot on Grub

Open D3vil0p3r opened this issue 1 year ago • 3 comments

I'm using Arch Linux with Zen Kernel and I'm using grub-btrfs + snapper-support package. I performed a test where: 1- I removed neofetch package 2- Created a file hello.txt 3- Removed malcontent package 4- Rebooted 5- Restoring on Grub by selecting the Snapshot related to the PRE-Install of neofetch package.

When I land on the system, effectively I see that I still have neofetch and malcontent packages installed as expected, but I see that hello.txt file still exists and I expected it was deleted since it didn't exist when I installed neofetch package.

Is there a way to manage files on snapshots by grub-btrfs or it works only with pacman packages?

D3vil0p3r avatar Sep 16 '23 16:09 D3vil0p3r

The snapshots you can boot with are always snapshot of the root subvolume (@) Could it be that you created the hello.txt file on a different subvolume?

Schievel1 avatar Sep 16 '23 20:09 Schievel1

I created it in my home folder. It has a different subvolume?

D3vil0p3r avatar Sep 16 '23 21:09 D3vil0p3r

It depends on how you setup your machine but most often yes, home is on a different subvolume

Maybe you can test that again and create the file in /hello.txt.

Otherwise what you think is going on here, that restoring subvolumes only restores files installed/ removed by pacman isn't possible. Subvolumes are always restored as a whole and they are not coupled with any program like pacman.

Schievel1 avatar Sep 17 '23 11:09 Schievel1