Assigning Quotas Per User - Red Hat ENTERPRISE LINUX 4 System Administration Manual

Hide thumbs Also See for ENTERPRISE LINUX 4:
Table of Contents

Advertisement

After quotacheck has finished running, the quota files corresponding to the enabled quotas (user
and/or group) are populated with data for each quota-enabled locally-mounted file system such as /
home.

13.1.4. Assigning Quotas per User

The last step is assigning the disk quotas with the edquota command.
To configure the quota for a user, as root in a shell prompt, execute the command:
edquota username
Perform this step for each user who needs a quota. For example, if a quota is enabled in /etc/fstab
for the /home partition (/dev/VolGroup00/LogVol02) and the command edquota testuser is
executed, the following is shown in the editor configured as the default for the system:
Disk quotas for user testuser (uid 501):
Filesystem
/dev/VolGroup00/LogVol02
Note
The text editor defined by the EDITOR environment variable is used by edquota. To
change the editor, set the EDITOR environment variable in your ~/.bash_profile file to
the full path of the editor of your choice.
The first column is the name of the file system that has a quota enabled for it. The second column
shows how many blocks the user is currently using. The next two columns are used to set soft and
hard block limits for the user on the file system. The inodes column shows how many inodes the user
is currently using. The last two columns are used to set the soft and hard inode limits for the user on
the file system.
A hard limit is the absolute maximum amount of disk space that a user or group can use. Once this
limit is reached, no further disk space can be used.
The soft limit defines the maximum amount of disk space that can be used. However, unlike the hard
limit, the soft limit can be exceeded for a certain amount of time. That time is known as the grace
period. The grace period can be expressed in seconds, minutes, hours, days, weeks, or months.
If any of the values are set to 0, that limit is not set. In the text editor, change the desired limits. For
example:
Disk quotas for user testuser (uid 501):
Filesystem
/dev/VolGroup00/LogVol02
To verify that the quota for the user has been set, use the command:
quota testuser
blocks
soft
hard
440436
0
blocks
soft
hard
440436
500000
550000
Assigning Quotas per User
inodes
soft
0
37418
0
inodes
soft
hard
37418
0
hard
0
0
119

Advertisement

Table of Contents
loading

Table of Contents