I try to remove btrfs snapshot as a normal user. I've read, that a user needs to have some special capability/right set: USER_SUBVOL_RM_ALLOWED
. How to grant such capability to user??
Asked
Active
Viewed 1,456 times
4

Adam Ryczkowski
- 4,403
- 9
- 40
- 65
1 Answers
2
This capability concerns mount point, not user (as it is suggested by the referenced question).
To add such capability one must remount/mount the filesystem with -o user_subvol_rm_allowed
option (case sensitive).
e.g. this is the mount command I use to mount the btrfs partition with my documents:
sudo mount -t btrfs -o remount,user_subvol_rm_allowed,compress,rw,noacl,noatime,autodefrag /dev/mapper/mydocs /home/adam/docs

Adam Ryczkowski
- 4,403
- 9
- 40
- 65
sudo mount -t btrfs -o USER_SUBVOL_RM_ALLOWED,compress,rw,noacl,noatime,autodefrag /dev/mapper/adam-docs /home/Adama-docs/Adam
with no effect. – Adam Ryczkowski Aug 10 '14 at 10:43bad option
error message. – Adam Ryczkowski Aug 10 '14 at 10:58