如何让openvz的VPS支持磁盘限额 quota?首先,openvz的vps需要母服务器管理员,也就是机房,来帮你开启quota,你自己是没有办法开启的。下面只是记录母服务器管理员开启特定的openvz的vps的磁盘限额的方法:
First-level quotas are enabled during the Container (or VPS) start-up process.
To see whether first-level quotas have already been enabled, issue the following command:
vzquota show 505
vzquota : (warning) Quota is running, so data reported from quota file may not reflect current values
   resource          usage       softlimit      hardlimit    grace
  1k-blocks        1572288        10485760       10485760         
     inodes          75774         5242880        5242880   
Second-level disk quotas are controlled by the QUOTAUGIDLIMIT parameter in the Container configuration file.
By default, the value of this parameter is zero, which disables per-user/group quotas. To view the parameter, issue the command:
If you get an empty result, or a result of zero, second-level quotas are not supported by this environment.
To turn on second-level quotas for the Container,
example:
vzctl stop 505
vzctl set "505" --quotaugidlimit 10000 --save
vzctl start 505
Starting container...
vzquota : (warning) quota usage is invalid for id 505, recalculating disk usage...
Container is mounted
Setting CPU limit: 100
Setting CPU units: 400
Setting CPUs: 1
Container start in progress...