On 8/31/16 5:48 PM, Chris Murphy wrote: > OK it looks like with -w flag I can get a reliable indication of > whether quota is enabled or not: > > [root@f24s ~]# btrfs quota enable /mnt/0 > [root@f24s ~]# btrfs quota rescan -w /mnt/0 > quota rescan started > [root@f24s ~]# btrfs quota disable /mnt/0 > [root@f24s ~]# btrfs quota rescan -w /mnt/0 > ERROR: quota rescan failed: Invalid argument > > > So if you did not enable quota support, and aren't sure if it's > enabled you can try 'btrfs quota rescan -w <mp>' but this might > actually be a bad idea, a rescan could take a while if you're actually > using quotas, I have no idea because I don't use them.
It can take a while, but the code is smart enough not to get too much in the way of other activity. It maintains a progress marker and only does live accounting on extents that have already been scanned. > Perhaps someone can point out an easier way to determine whether > quotas are enabled? btrfs qgroup show <path> If you get a message like: ERROR: can't perform the search - No such file or directory ERROR: can't list qgroups: No such file or directory ... it means there's no quota root and thus quotas aren't enabled. -Jeff -- Jeff Mahoney SUSE Labs
signature.asc
Description: OpenPGP digital signature