4.4.5. Disabling/Enabling Quota Accounting

4.4.5. Disabling/Enabling Quota Accounting

By default, quota accounting is enabled; therefore, GFS keeps track of disk usage for every user and group even when no quota limits have been set. Quota accounting incurs unnecessary overhead if quotas are not used. You can disable quota accounting completely by setting the quota_account tunable parameter to 0. This must be done on each node and after each mount. (The 0 setting is not persistent across unmounts.) Quota accounting can be enabled by setting the quota_account tunable parameter to 1.

Usage

fs_tool settune MountPoint quota_account {0|1}
MountPoint

Specifies the GFS file system to which the actions apply.

quota_account {0|1}

0 = disabled

1 = enabled

Comments

To enable quota accounting on a file system, the quota_account parameter must be set back to 1. Afterward, the GFS quota file must be initialized to account for all current disk usage for users and groups on the file system. The quota file is initialized by running: gfs_quota init -f MountPoint.

Note

Initializing the quota file requires scanning the entire file system and may take a long time.

Examples

This example disables quota accounting on file system /gfs on a single node.

gfs_tool settune /gfs quota_account 0

This example enables quota accounting on file system /gfs on a single node and initializes the quota file.

# gfs_tool settune /gfs quota_account 1
# gfs_quota init -f /gfs

Note: This documentation is provided {and copyrighted} by Red Hat®, Inc. and is released via the Open Publication License. The copyright holder has added the further requirement that Distribution of substantively modified versions of this document is prohibited without the explicit permission of the copyright holder. The CentOS project redistributes these original works (in their unmodified form) as a reference for CentOS-4 because CentOS-4 is built from publicly available, open source SRPMS. The documentation is unmodified to be compliant with upstream distribution policy. Neither CentOS-4 nor the CentOS Project are in any way affiliated with or sponsored by Red Hat®, Inc.