Re: Unable to delete BTRFS snapshot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Aug 3, 2021 at 1:51 AM Sreyan Chakravarty <sreyan32@xxxxxxxxx> wrote:
>
> Hi,
>
> I am faced with a strange problem. I have a BTRFS snapshot that I want to delete but just can't.
>
> So I always manipulate BTRFS snapshots from a live-cd environment which I setup using the following commands:
>
> sudo cryptsetup open /dev/sda3 dm-crypt
> <<GIVE PASSWORD>>
> sudo mount /dev/mapper/dm-crypt /mnt
>
> Now I can query the snapshots:
>
> $ sudo btrfs subvolume list /mnt
> ID 448 gen 235989 top level 5 path root
> ID 449 gen 0 top level 5 path before_live_cd_exp
>
> I want to delete the snapshot "before_live_cd_exp", which I am unable to do:
>
> $ sudo btrfs subvolume delete /mnt/before_live_cd_exp/
> ERROR: Not a Btrfs subvolume: Invalid argument
>
> What does it mean it's not a Btrfs subvolume ? It was picked up by the list command.
>
> I also tried via the subvolid:
>
> $ sudo btrfs subvolume delete --subvolid 449 /mnt
> Delete subvolume (no-commit): '/mnt/before_live_cd_exp'
> ERROR: Could not destroy subvolume/snapshot: No such file or directory

What messages appear in dmesg and coincide with the failed command?

I haven't heard of anyone being unable to delete snapshots before. But
also suspicious about this particular snapshot (which I also haven't
ever seen) is its generation is 0. Even brand new subvolumes on a
brand new file system have non-zero generation.


> This is even weirder since as you can clearly see the directory exists in the given path.
>
> Any suggestions on what is going wrong ?
>
> I should tell you that a while back I had a huge BTRFS file system crash, and it took a lot of targeted help from the community to get my system to boot.

This could be a side effect of an incomplete repair.


-- 
Chris Murphy
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/users@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux