Whamcloud - gitweb
LU-15277 utils: lfs quota/setquota improvements
[fs/lustre-release.git] / lustre / doc / lfs-setquota.1
index 71349d2..92b4f6d 100644 (file)
@@ -1,27 +1,26 @@
-.TH LFS-SETQUOTA 1 2017-07-21 "Lustre" "Lustre Utilities"
+.TH LFS-SETQUOTA 1 2022-02-26 "Lustre" "Lustre Utilities"
 .SH NAME
 lfs-setquota \- set quota limits or grace time for users, groups or projects.
 .SH SYNOPSIS
-.BR "lfs setquota " { -u | --user | -g | --group | -p | --projid "} " \fIUID | \fIGID | \fIPROJID
-       [\fB--pool \fIPOOLNAME ]
-       [\fB--block-softlimit\fR|\fB-b \fIBLOCK_SOFTLIMIT\fR[\fBkMGTPE\fR]]
-       [\fB--block-hardlimit\fR|\fB-B \fIBLOCK_HARDLIMIT\fR[\fBkMGTPE\fR]]
-       [\fB--inode-softlimit\fR|\fB-i \fIINODE_SOFTLIMIT\fR[\fBkMGTPE\fR]]
-       [\fB--inode-hardlimit\fR|\fB-I \fIINODE_HARDLIMIT\fR[\fBkMGTPE\fR]] <\fIfilesystem\fR>
-.TP
-.BR "lfs setquota -t " { -h | -u | -g | -p }
-       [\fB--pool\fR \fIPOOL_NAME\fR]
-       [\fB--block-grace\fR|\fB-b\fR \fIBLOCK_GRACE_TIME\fR]
-       [\fB--inode-grace\fR|\fB-i\fR \fIINODE_GRACE_TIME\fR] <\fIfilesystem\fR>
+.BR "lfs setquota " { -u | --user | -g | --group | -p | --projid "} " \fIID
+[\fB--pool \fIPOOLNAME\fR]
+       [\fB-b|\fB--block-softlimit\fR \fIBLOCK_SOFTLIMIT\fR[\fBKMGTPE\fR]]
+       [\fB-B|\fB--block-hardlimit\fR \fIBLOCK_HARDLIMIT\fR[\fBKMGTPE\fR]]
+       [\fB-i|\fB--inode-softlimit\fR \fIINODE_SOFTLIMIT\fR[\fBKMGTPE\fR]]
+       [\fB-I|\fB--inode-hardlimit\fR \fIINODE_HARDLIMIT\fR[\fBKMGTPE\fR]] \fIFILESYSTEM
 .TP
-.BR "lfs setquota " { -u | --user | -g | --group | -p | --projid "} " \fIUID\fR|\fIGID\fR|\fIPROJID\fR
-       [\fB--default|-D\fR] <\fIfilesystem\fR>
+.BR "lfs setquota " { -u | --user | -g | --group | -p | --projid "} " \fIID
+ {\fB--default\fR|\fB-D\fR|\fB--delete\fR} \fIFILESYSTEM
+.TP
+.BR "lfs setquota " { -t | --times "} {" -h | -u | -g | -p "} [" "--pool " \fIPOOLNAME ]
+ [\fB-b\fR|\fB--block-grace\fR \fIBLOCK_GRACE_TIME\fR]
+ [\fB-i\fR|\fB--inode-grace\fR \fIINODE_GRACE_TIME\fR] \fIFILESYSTEM
 .TP
 .BR "lfs setquota " { -U | --default-usr | -G | --default-grp | -P | --default-prj }
-       [\fB--block-softlimit\fR|\fB-b\fR \fIBLOCK_SOFTLIMIT\fR[\fBkMGTPE\fR]]
-       [\fB--block-hardlimit\fR|\fB-B\fR \fIBLOCK_HARDLIMIT\fR[\fBkMGTPE\fR]]
-       [\fB--inode-softlimit\fR|\fB-i\fR \fIINODE_SOFTLIMIT\fR[\fBkMGTPE\fR]]
-       [\fB--inode-hardlimit\fR|\fB-I\fR \fIINODE_HARDLIMIT\fR[\fBkMGTPE\fR]] <\fIfilesystem\fR>
+       [\fB-b\fR|\fB--block-softlimit\fR \fIBLOCK_SOFTLIMIT\fR[\fBKMGTPE\fR]]
+       [\fB-B\fR|\fB--block-hardlimit\fR \fIBLOCK_HARDLIMIT\fR[\fBKMGTPE\fR]]
+       [\fB-i\fR|\fB--inode-softlimit\fR \fIINODE_SOFTLIMIT\fR[\fBKMGTPE\fR]]
+       [\fB-I\fR|\fB--inode-hardlimit\fR \fIINODE_HARDLIMIT\fR[\fBKMGTPE\fR]] \fIFILESYSTEM
 .TP
 .BR "lfs setquota " { -u | --user | -g | --group | -p | --projid "} " \fIUID\fR|\fIGID\fR|\fIPROJID\fR
        [\fB--delete\fR] <\fIfilesystem\fR>
@@ -30,94 +29,99 @@ lfs-setquota \- set quota limits or grace time for users, groups or projects.
 .TP
 .SH DESCRIPTION
 .TP
-.BR "lfs setquota " {\fB-u|-g|-p\fR}
-Command sets the filesystem quotas for users, groups or projects respectively.
-Block limits unit is kilobyte (1024) by default and block limits are always
-kilobyte-grained (even if specified in bytes), block limits can be specified
+.BR "lfs setquota " { -u | -g | -p }
+Command sets the filesystem quotas for users, groups, or projects respectively.
+Block limits unit is kilobyte (1024) by default, and block limits are always
+kilobyte-granular (even if specified in bytes), block limits can be specified
 with a
-.BR k "," M "," G "," T "," P ", or " E
-suffixes which specify units of 2^10, 2^20, 2^30, 2^40, 2^50 and 2^60
-accordingly.
+.BR K ", " M ", " G ", " T ", " P ", or " E
+suffix to specify units of 2^10, 2^20, 2^30, 2^40, 2^50 and 2^60 bytes
+respectively.
 .TP
-.BR -b | --block-softlimit \fIBLOCK_SOFTLIMIT
+.BR -b | --block-softlimit " " \fIBLOCK_SOFTLIMIT
 Specify block softlimit, zero means unlimited.
 .TP
-.BR -B | --block-hardlimit \fIBLOCK_HARDLIMIT
+.BR -B | --block-hardlimit " " \fIBLOCK_HARDLIMIT
 Specify block hardlimit, zero means unlimited. The block hardlimit should be
-greater than block softlimit when it's being specified.
+greater than the block softlimit if it is being specified.
 .TP
 .BR --delete
-Delete the unused UID|GID|PROJID.
+Delete the unused user, group, or project \fIID\fR limit.
 .TP
 .BR -D|--default
 Set user/group/project to use the default quota limits.
 .TP
-.BR -g | --group \fIGROUPNAME\fR|\fIGID
-Set group quota for name \fIGROUPNAME\fR or \fIGID\fR.
+.BR -g | --group " " \fIGROUPNAME | \fIGID
+Set group quota for name \fIGROUPNAME\fR or numeric \fIGID\fR.
 .TP
 .BR -h | --help
 Print usage message.
 .TP
-.BR -i | --inode-softlimit \fIINODE_SOFTLIMIT
+.BR -i | --inode-softlimit " " \fIINODE_SOFTLIMIT
 Specify inode softlimit, zero means unlimited.
 .TP
-.B -I|--inode-hardlimit \fIINODE_HARDLIMIT\fR
+.BR -I | --inode-hardlimit " " \fIINODE_HARDLIMIT
 Specify inode hardlimit, zero means unlimited. The inode hardlimit should be
 greater than inode softlimit when it's being specified.
 .TP
-.B -p|--project \fIPROJID\fR
-Set project quota for \fIPROJID\fR.
+.BR -p | --project " " \fIPROJID
+Set project quota for numeric \fIPROJID\fR.
 .TP
-.B --pool \fIPOOL_NAME\fR
+.BR --pool " " \fIPOOL_NAME
 Set quota per OST pool \fIPOOL_NAME\fR.
 .TP
 .BR -r
 Reset the internal quota data of the user|group|project quota. It can be used
 to fix the quota containing corrupted internal data (such as, the quota grant).
 .TP
-.BR -u | --user \fIUSERNAME\fR|\fBUID
-Set user quota for \fIUNAME\fR or \fIUID\fR.
+.BR -u | --user " " \fIUSERNAME | \fIUID
+Set user quota for \fIUNAME\fR or numeric \fIUID\fR.
 .PP
 .TP
-.BR "lfs setquota -t " { -h | -u | -g | -p "} " \fIGRACE_TIME
+.BR "lfs setquota " { -t | --times "} {" -h | -u | -g | -p "} " \fIGRACE_TIME
 Command sets the filesystem quota grace time for users, groups, or projects.
 The
 .I GRACE_TIME
 is a global value that can take two forms: an amount of time or the word
 .BR notify .
-Traditionally, this indicates the amount of time in seconds
+Traditionally,
+.I GRACE_TIME indicates the amount of time in seconds
 that the soft quota limit can be exceeded before users are prevented from
 creating new files or consuming more space.  This is intended to allow users
 to exceed the quota limit for a short time to complete their work without
-having to grant each user a larger hard quota limit. The alternative value of
+having to grant each user a larger hard quota limit.
+.PP
+The alternative value of
 .B notify
-informs users with an '\fB*\fR' in the quota output that they
-are nearing their hard quota limit but does not block new writes until the hard
+informs users that are exceeding their soft quota limit (an '\fB*\fR' in the
+quota output) that they
+are nearing their hard quota limit, but does not block new writes until the hard
 quota limit is reached.  The soft quota state is reset once the user, group,
 or project reduces their space usage or file count below the soft quota limit.
 Grace time is specified in "XXwXXdXXhXXmXXs" format or as an integer seconds
 value.  The maximum is 2^48 - 1 seconds.
 .TP
-.B -t
+.BR -t | --times
 Set quota grace times.
 .TP
-.B -u
+.BR -u | --user
 Set grace time for user.
 .TP
-.B -g
+.BR -g | --group
 Set grace time for group.
 .TP
-.B -p
+.BR -p | --projid
 Set grace time for project.
 .TP
-.BR -b | "--block-grace notify" | \fIBLOCK_GRACE_TIME\fR
-Specify grace time for block quota.
+.BR -b | --block-grace " {" notify | \fIBLOCK_GRACE_TIME }
+Specify grace time for block quota in seconds.
 .TP
-.BR -i | "--inode-grace notify" | \fIINODE_GRACE_TIME\fR
-Specify grace time for inode quota.
+.BR -i | --inode-grace " {" notify | \fIBLOCK_GRACE_TIME }
+Specify grace time for inode quota in seconds.
 .TP
-.B --pool \fIPOOL_NAME\fR
+.BR --pool " " \fIPOOL_NAME
 Set grace time for user, group or project per OST pool \fIPOOL_NAME\fR.
+.PP
 .TP
 .BR "lfs setquota " { -U | --default-usr | -G | --default-grp | -P | --default-prj }
 Command sets the filesystem default limits for user, group, project quotas,
@@ -129,7 +133,7 @@ Set default user quota limit.
 .TP
 .BR -G | --default-grp
 Set default group quota limit.
-.TP
+.T
 .BR -P | --default-prj
 Set default project quota limit.
 .TP
@@ -139,24 +143,24 @@ Set default project quota limit.
 .B $ lfs setquota -u bob --block-softlimit 2G --block-hardlimit 1G /mnt/lustre
 Set quotas of user `bob': 1GB block hardlimit and 2 GB block softlimit
 .TP
-.B $ lfs setquota -u bob -D /mnt/lustre
+.B $ lfs setquota -u bob --default /mnt/lustre
 Set quotas of user `bob' to use default quota setting
 .TP
 .B $ lfs setquota -U --block-softlimit 1G --block-hardlimit 2G /mnt/lustre
 Set system default user quota: 1 GB block softlimit and 2 GB block hardlimit
 .TP
-.B $ lfs setquota -t -u --block-grace 1000 --inode-grace 1w4d /mnt/lustre
-Set grace times for user quotas: 1000 seconds for block quotas, 1 week and 4
+.B $ lfs setquota -t -u --block-grace 36000 --inode-grace 1w4d /mnt/lustre
+Set grace times for user quotas: 36000 seconds for block quotas, 1 week and 4
 days for inode quotas
 .TP
 .B $ lfs setquota -u ivan --pool flash_pool -B 1G /mnt/lustre
 Set hard block limit 1G for user 'ivan' per pool 'flash_pool'
 .TP
-.B $ lfs setquota -t -u --block-grace 1000 --pool flash_pool /mnt/lustre
-Set grace time 1000 seconds for block quotas per pool 'flash_pool'
+.B $ lfs setquota -t -u --block-grace 10000 --pool flash_pool /mnt/lustre
+Set grace time 10000 seconds for block quotas per pool 'flash_pool'
 .TP
 .BR "lfs setquota " { -u | -g | -p "} " \fIUID\fR|\fIGID\fR|\fIPROJID\fR " " [\fB--delete\fR] " " <\fIfilesystem\fR>
-Command deletes the unused UID|GID|PROJID from Quota settings.
+Command deletes the unused user, group, or project \fIID\fR from quota settings.
 .TP
 .PP
 .SH EXAMPLES