btrfs-progs
btrfs-progs copied to clipboard
subvolume delete: add option to remove the associated qgroup
When a subvolume gets an associated qgroup 0/id, it's not deleted together with the subvolume. Lots of people complain about that and nobody knows why this hasn't been implemented.
There are potential backward compatibility concerns, when scripts could delete the qgroup unconditionally.
To implement:
- new options
--delete-qgroupthat will delete the qgroup, and--no-delete-qgroup - use the separate ioctl QGROUP_CREATE for deletion
- switch default action to delete the qgroup
To test:
- passing the new options does not fail when qgroups are not enabled
- --delete-qgroup with a subvolume in a deeper qgroup hierarchy works