Resolution
If you see error message like this trying to manage users' quotas inside a container:
edquota: Can't write quota for 32063 on /dev/vzfs: No such process
Resetting quota for admin2 to 0 Meg....Donethen probably its reason is that second-level quota limit is exceeded and user quotas above a limit were not loaded.
Please increase QUOTAUGIDLIMIT parameter value for a container to the number which is greater than sum of users and groups created (or supposed to be created) in a container.
This command will show you current usage of second-level quotas in a container #101, you may run it on a hardware node:
# wc -l /vz/root/101/etc/{passwd,group}
95 /vz/root/101/etc/passwd
107 /vz/root/101/etc/group
202 total
You may increase QUOTAUGIDLIMIT parameter using 'vzctl' utility on a node:
# vzctl set 101 --save --quotaugidlimit 210
To apply changes it is required to restart container:
# vzctl restart 101