If you have a Virtuozzo 4.7 VPS, there are a few additional steps that must be taken to enable quotas in this environment.
This is due to the nature of Virtuozzo quota types; First level quotas and Second level quotas.
What is a container?
The container is a spun up virtualized instance. This instance is going to be the virtual server in which you will be hosting your website, emails, databases, and other various web hosting information.
Finding the Container_ID
You will need to find the container ID. This can be achieved by running the following command:
CTID NPROC STATUS IP_ADDR HOSTNAME
1 135 running 10.101.60.79 localhost
101 8 running 10.101.66.1 ct101.parallels.com
102 7 running 10.101.66.159 ct102.parallels.com
103 - stopped 10.101.66.103 ct103.parallels.com
We can see the first entry in bold is the CTID, which is the Container_ID.
First Level Quotas
First Level quotas should be enabled by the Virtuozzo environment when it starts up the container, as such you simply need to verify that it is enabled.
Run the following command to verify First Level quotas; where
Container_ID represents the container ID of the container that you wish to check:
vzquota show Container_ID
Second Level Quotas
Perform the following steps:
QUOTAUGIDLIMITparameter to a value that is greater than zero. This can be seen below in step 2.
Run the following command to enable second-level quotas, where
Container_IDrepresents the container ID of the container that you wish enable second-level quotas on.
vzquota on Container_ID -s 1
- Restart the Container.
vzctl restart Container_ID