What Makes RHEL7.0 Robust?October 21, 2014
Interview Questions Faced by SYED PARVEZ ZAFAR, RHCENovember 25, 2014
Disk space can be restricted by implementing disk quotas which alert a system administrator before a user consumes too much disk space or a partition becomes full.
Disk quotas can be configured for individual users as well as user groups.
In addition, quotas can be set not just to control the number of disk blocks consumed but to control the number of inodes.
The quota RPM must be installed to implement disk quota.
To implement disk quotas, use the following steps:
As root, using a text editor, edit the /etc/fstab file.
/dev/aemvg/aemlv /home ext4 defaults,usrquota,grpquota 0 0
Remounting the File System
mount -o remount /home
Creating the Quota Database Files
To create the quota files (aquota.user and aquota.group) on the file system, use the -c option of the quotacheck command.
quotacheck -cug /home
After the files are created, run the following command to generate the table of current disk usage per file system with quotas enabled:
Assigning Quotas per User
edquota username OR
setquota -u student 2048 4096 /home
Enabling and Disabling
Display Quota Status
Enable quotas per file system by modifying the /etc/fstab file.
Remount the file system(s).
Create the quota database files and generate the disk usage table.
Assign quota policies.