SETQUOTA(8)
π SETQUOTA β bestie's guide to setting disk quotas π
okay so welcome to the glow-up of setquota(8), straight out of the System Manager's Manual. no cap, this is the tool that edits disk quotas from the command line, and by the end of this page you're gonna be so good at it. let's go π«Ά
β¨ NAME β¨
setquota β set disk quotas. short, sweet, iconic. that's the whole name section, bestie, we move. π
π¦ SYNOPSIS π¦
like, here's every single way you can call her. all five forms, verbatim, no edits:
setquota [ -rm ] [ -u | -g | -P ] [ -F quotaformat ] name block-
softlimit block-hardlimit inode-softlimit inode-hardlimit -a |
filesystem...
setquota [ -rm ] [ -u | -g | -P ] [ -F quotaformat ] [ -p protoname ]
name -a | filesystem...
setquota -b [ -rm ] [ -u | -g | -P ] [ -F quotaformat ] -a |
filesystem...
setquota -t [ -u | -g | -P ] [ -F quotaformat ] block-grace inode-grace
-a | filesystem...
setquota -T [ -u | -g | -P ] [ -F quotaformat ] name block-grace inode-
grace -a | filesystem...
πΈ DESCRIPTION πΈ
so setquota is a command line quota editor. main character energy fr fr. you tell it the filesystem, the user/group/project name, and the new quotas for that filesystem, all right there on the command line. π
ngl, tiny little detail that matters: if you hand it a number instead of a user/group/project name, it treats that number as an UID/GID/project ID. so don't be surprised when it does exactly that. iykyk.
π₯ OPTIONS π₯
-r,--remoteβ also edits remote quota, usingrpc.rquotadon the remote server to set the quota. lowkey important: this one only works if the quota tools were compiled with support for setting quotas over RPC enabled. no support, no remote, periodt.-m,--no-mixed-pathnamesβ okay so rn, pathnames of NFSv4 mountpoints get sent without a leading slash in the path.rpc.rquotaduses that missing slash to recognize NFSv4 mounts and properly prepend the pseudoroot of the NFS filesystem to the path. if you pass this option,setquotawill always send paths with a leading slash. cute for legacy reasons, but be aware: quota over RPC will stop working if you're using the newrpc.rquotad. π-F,--format=quotaformatβ do the setting for a specified format, i.e. don't do format autodetection. possible format names are:vfsoldβ Original quota format with 16-bit UIDs / GIDsvfsv0β Quota format with 32-bit UIDs / GIDs, 64-bit space usage, 32-bit inode usage and limitsvfsv1β Quota format with 64-bit quota limits and usagerpcβ (quota over NFS)xfsβ (quota on XFS filesystem)
-u,--userβ set user quotas for the named user. this is the default, so if you don't say anything, this is what you get. π-g,--groupβ set group quotas for the named group.-P,--projectβ set project quotas for the named project.-p,--prototype=protonameβ use the quota settings of user, group or projectprotonameto set the quota for the named user, group or project. copy-paste but make it quota. β¨--always-resolveβ always try to translate user / group / project name to uid / gid / project ID, even if the name is composed of digits only. (yes, even then. stubborn on purpose.)-b,--batchβ read the info to set fromstdin. the input format isname block-softlimit block-hardlimit inode-softlimit inode-hardlimit. empty lines and lines starting with#are ignored. bulk mode, we love to see it. π-c,--continue-batchβ if parsing of an input line in batch mode fails, just keep going and process the next line. resilience queen. π-t,--edit-periodβ set grace times for users/groups/projects. the timesblock-graceandinode-graceare specified in seconds.-T,--edit-timesβ alter times for individual user/group/project when softlimit is enforced. the timesblock-graceandinode-graceare specified in seconds, or they can be the string'unset'. β°-a,--allβ go through all filesystems with quota in/etc/mtaband perform the setting. yes, all of them. no, it does not ask twice.
π« the numbers part (do not skip this, bestie) π«
block-softlimit and block-hardlimit are interpreted as multiples of kibibyte (1024 bytes) blocks by default. and you can slap a symbol on the end of a numeric value to express kibibytes, mebibytes, gibibytes and tebibytes:
Kβ kibibytesMβ mebibytesGβ gibibytesTβ tebibytes
inode-softlimit and inode-hardlimit are interpreted literally. you can append k, m, g, and t to a numeric value to express multiples of 10^3, 10^6, 10^9, and 10^12 inodes. (yes, lowercase β and yes, decimal, not binary. the vibes are different on purpose. π)
to disable a quota, set the corresponding parameter to 0. to change quotas for several filesystems, invoke it once for each filesystem. one at a time, babe.
and this one is non-negotiable: only the super-user may edit quotas. π
π§ FILES π§
aquota.useroraquota.groupβ quota file at the filesystem root (version 2 quota, non-XFS filesystems)quota.userorquota.groupβ quota file at the filesystem root (version 1 quota, non-XFS filesystems)/etc/mtabβ mounted filesystem table
π SEE ALSO π
go read these too, they're all part of the lore:
and that's the whole page, bestie!! π this was SETQUOTA(8) from the System Manager's Manual β go forth and set those quotas, you absolute legend. mwah ππ¦π
π¦ where this page comes from
- alpine 3.24: quota-tools-doc 4.11-r0 Β· GPL-2.0-or-later
- centos-stream 10: quota 1:4.09-10.el10 Β· GPL-2.0-only AND GPL-2.0-or-later
- centos-stream 9: quota 1:4.09-4.el9 Β· GPLv2 and GPLv2+
- debian bookworm: quota 4.06-1+b2
- debian trixie: quota 4.09-1+b1
- fedora 43: quota 1:4.10-2.fc43 Β· GPL-2.0-only AND GPL-2.0-or-later
- fedora 44: quota 1:4.11-2.fc44 Β· GPL-2.0-only AND GPL-2.0-or-later
- nixpkgs unstable: quota 4.11
- opensuse-leap 16.0: quota 4.09-160000.3.1 Β· GPL-2.0-only
- opensuse-leap 16.0: quota 4.09-160000.3.1 Β· GPL-2.0-only
- opensuse-leap 16.0: quota 4.09-160000.3.1 Β· GPL-2.0-only
- opensuse-leap 16.0: quota 4.09-160000.3.1 Β· GPL-2.0-only
- ubuntu jammy: quota 4.06-1build2
- ubuntu noble: quota 4.06-1build6
- ubuntu questing: quota 4.09-1
- ubuntu resolute: quota 4.09-1build1
- ubuntu stonking: quota 4.11-1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms