Table of Contents
Background
You’ve just deployed a new Ubuntu server, but Virtualmin Quotas are reported as not active.
On some hosted Ubuntu servers you have to install the kernel sources, and reboot, before quotas will work.
apt-get -y install linux-image-generic
At this point it’s worth just trying again. If in Webmin you get this:
Failed to turn on quotas : quotaon: using //aquota.user on /dev/sda1 [/]: No such process quotaon: Quota format not supported in kernel.
Just try again.
Then try this:
apt-get -y install linux-headers-generic
Additionally try this:
apt-get -y install linux-image-extra-uname -r
Getting Quotas working on XFS
To get quotas working with Virtualmin and XFS, two items needs to be present:
> cat /etc/fstab
/dev/mapper/centos-root / xfs quota,attr2,grpquota,usrquota,inode64,relatime,rw 0 0
> cat /etc/default/grub
GRUB_CMDLINE_LINUX="rd.lvm.lv=centos/root rd.lvm.lv=centos/swap rhgb quiet rootflags=uquota,gquota"
To activate the GRUB changes, do this:
grub2-mkconfig -o /boot/grub2/grub.cfg
Getting Quotas Working on GCP (Google Cloud Platform)
On GCP, this was the breakthrough, first install it then reboot
sudo apt-get install linux-modules-extra-gcp
References
- https://serverfault.com/questions/1067391/google-cloud-platform-ubuntu-pro-quota-format-not-supported-in-kernel
- XFS Information supplied by Keith Williams
- https://www.digitalocean.com/community/questions/quotas-are-not-enabled-on-the-filesystem-which-contains-home-directories-under-home-and-email-files-under-home-quota-editing-has-been-disabled
- https://www.digitalocean.com/community/tutorials/how-to-enable-user-and-group-quotas