Quotas are not enabled after reboot of server

Running a VPS with Cent OS 5.2. When I reboot the server and run Re-check config, I get the message:

Quotas are not enabled on the filesystem / which contains home directories under /home and email files under /home. Quota editing has been disabled

When I look at the settings under webmin I have to reset and re-enable the disk quotas. I then run Re-Check config and all is well until I reboot.

-Jeff

Some types of VPS (OpenVZ, Virtuozzo, vservers, maybe others) copy an mtab and fstab in from the host system…so when Webmin modifies it, it gets overwritten on reboot.

Figure out where those files are coming from and enable quotas there.

Hi Joe,

I am running under Xen. Asked the provider, they said, they are not stomping on any quota files at boot. They referred me to the CentOS docs at http://www.centos.org/docs/5/html/Deployment_Guide-en-US/ch-disk-quotas.html#s1-disk-quotas-configuring

Lots of info, but all referring to /etc/fstab - In the Virtualmin setup guide for CentOS, it says to change fstab to mtab as follows:

Configurable options for Disk and Network Filesystems (System configuration)
File listing filesystems mounted at boot time: /etc/mtab

I did that, but maybe it should be left as the default fstab?

-Jeff

I am running under Xen.

Xen is not one of those VPS types that does this. :wink:

I’m surprised Webmin is detecting quotas as being not enabled. Xen looks like a regular system, generally, in this regard. Do the quota commands work right after reboot?

In the Virtualmin setup guide for CentOS, it says to change fstab to mtab as follows:

What setup guide are you talking about? I don’t remember ever writing those words. And either should, technically, work in a real system. I can’t think of why anyone would suggest such a change in any normal circumstance.

The quota settings work until I reboot, then they have to be reset and saved.

Docs where I got the info:

http://www.virtualmin.com/documentation/id,centos_5_install/

Howdy,

I’m curious about two things – can you show us a copy of your /etc/fstab file now, and then another copy of it after you do a reboot?

I just want to make sure that nothing odd is going on in there, as some things need to be enabled there for quotas to work properly.
-Eric

This file is edited by fstab-sync - see ‘man fstab-sync’ for details

/dev/sda1 / ext3 errors=remount-ro,noatime 0 1
/dev/sda2 none swap sw 0 0
proc /proc proc defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0

After switching to /etc/fstab and re-booting, running check configuration, I get:

The module could not find the mount point for your home directories filesystem /home. Quotas editing has been disabled.

-Jeff

Sorry, missed your request for the before and after shot.

-Jeff

File listing filesystems mounted at boot time: /etc/mtab
—before reboot no error in config check
/etc/mtab
/dev/sda1 / ext3 grpquota,suid,dev,noatime,usrquota,exec 0 0
proc /proc proc rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

/etc/fstab

This file is edited by fstab-sync - see ‘man fstab-sync’ for details

/dev/sda1 / ext3 errors=remount-ro,noatime 0 1
/dev/sda2 none swap sw 0 0
proc /proc proc defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0

—after reboot error message in config check
Quotas are not enabled on the filesystem / which contains home directories under /home and email files under /home. Quota editing has been disabled.

/etc/mtab
/dev/sda1 / ext3 rw,noatime,errors=remount-ro 0 0
proc /proc proc rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

/etc/fstab

This file is edited by fstab-sync - see ‘man fstab-sync’ for details

/dev/sda1 / ext3 errors=remount-ro,noatime 0 1
/dev/sda2 none swap sw 0 0
proc /proc proc defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0


File listing filesystems mounted at boot time: /etc/fstab
—before reboot error message in config check
The module could not find the mount point for your home directories filesystem /home. Quotas editing has been disabled.

/etc/mtab
/dev/sda1 / ext3 rw,noatime,grpquota,usrquota 0 0
proc /proc proc rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

/etc/fstab

This file is edited by fstab-sync - see ‘man fstab-sync’ for details

/dev/sda1 / ext3 errors=remount-ro,noatime 0 1
/dev/sda2 none swap sw 0 0
proc /proc proc defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0

—after reboot error message in config check
The module could not find the mount point for your home directories filesystem /home. Quotas editing has been disabled.

/etc/mtab
/dev/sda1 / ext3 rw,noatime,errors=remount-ro 0 0
proc /proc proc rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

/etc/fstab

This file is edited by fstab-sync - see ‘man fstab-sync’ for details

/dev/sda1 / ext3 errors=remount-ro,noatime 0 1
/dev/sda2 none swap sw 0 0
proc /proc proc defaults 0 0
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0

Yeah, it looks like your fstab is changing across reboots.

For quotas to work, the usrquota and grpquota bit, seen in your first example, need to be in it.

But in your second example, that’s no longer present.

So something is modifying the fstab file… that’s the problem :slight_smile:
-Eric

It looks like the /etc/mtab file is the one being modified.

Should the File listing filesystems mounted at boot time: be /etc/mtab or /etc/fstab?

The hosting company claims that nothing is being modified by them, any suggestions on how to track this down?

-Jeff

—before reboot no error in config check
/etc/mtab
/dev/sda1 / ext3 grpquota,suid,dev,noatime,usrquota,exec 0 0
proc /proc proc rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

—after reboot error message in config check
Quotas are not enabled on the filesystem / which contains home directories under /home and email files under /home. Quota editing has been disabled.
/etc/mtab
/dev/sda1 / ext3 rw,noatime,errors=remount-ro 0 0
proc /proc proc rw 0 0
none /dev/pts devpts rw,gid=5,mode=620 0 0
none /dev/shm tmpfs rw 0 0
none /proc/sys/fs/binfmt_misc binfmt_misc rw 0 0

Should the File listing filesystems mounted at boot time: be /etc/mtab or /etc/fstab?

As I mentioned above, it shouldn’t matter.

fstab is the configuration file that determines what is mounted during boot, mtab is what is currently mounted and with what options.

On some virtualized system types mtab is faked…but Xen is not one of them, as I also mentioned (so your host is correct, mtab is not copied in from outside on a Xen system).

So, on reboot quotas are not being turned on, because fstab doesn’t include the quota options. So, figure out why fstab is being altered to not include quotas, and you’ll find the source of your troubles. Virtualmin/Webmin obviously aren’t doing it.

Disabled quotas in webmin

Ran quotacheck -m / via ssh terminal.

Enabled quotqs in webmin.

Quotas still working after reboot

-Jeff