Setting storage limits for users and groups

Imposing limits on the amount of storage a user can consume is an effective way to manage resources and ensure they are made available to everyone fairly, especially in a multiuser environment. This recipe shows you how to enable quotas and set limits by users and groups.

Getting ready

This recipe requires a CentOS system with administrative privileges provided by logging in with the root account or using sudo. It assumes /home mounts its own filesystem.

How to do it...

Follow these steps to set up quotas and specify storage limits:

  1. Open the /etc/fstab file for editing:
    vi /etc/fstab
  2. To enable user quotas, which enforce usage limits based on user accounts, add uquota to the mount options for /home. For group ...

Get CentOS 7 Server Deployment Cookbook now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.