2010
01.26

There is a small how to here however it describes how to install on / partition. Here are clear instructions for /home.

Login as root, do not use sudo, you will not be able to unmount /home partition if you use sudo.

Install quota

user@computer:$ apt-get install quota

Change mount options

user@computer:$ vim /etc/fstab

And use following options for /home partition:

errors=remount-ro,usrjquota=aquota.user,grpjquota=aquota.group,jqfmt=vfsv0

Here is example /etc/fstab file:

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/sda1       /               ext3    errors=remount-ro 0       1
/dev/sdb1       /home           ext3    errors=remount-ro,usrjquota=aquota.user,grpjquota=aquota.group,jqfmt=vfsv0        0       2
/dev/sda5       none            swap    sw              0       0
/dev/hdc        /media/cdrom0   udf,iso9660 user,noauto     0       0
/dev/fd0        /media/floppy0  auto    rw,user,noauto  0       0

Create user and group file

user@computer:$ cd /home
touch aquota.user aquota.group

Remount /home

user@computer:$ umount /home
mount /home

Run following commands

user@computer:$ quotacheck -avugm
quotaon -avug

Quota is now enabled on your server

user@computer:$ repquota -u /home
*** Report for user quotas on device /dev/sdb1
Block grace time: 7days; Inode grace time: 7days
Block limits File limits
User used soft hard grace used soft hard grace
----------------------------------------------------------------------
root -- 131212 0 0 2 0 0
artur -- 24 0 0 6 0 0

Bookmark and Share

No Comment.

Add Your Comment