How to Increase Inode Value in a VPS Container
Introduction
In some VPS environments, you may receive a Disk quota exceeded error even when sufficient disk space is available. This usually happens when the inode limit has been fully utilised.
An inode stores metadata about files. When the inode usage reaches 100%, new files cannot be created even if free disk space exists.
Prerequisites
Before proceeding, ensure:
- Root SSH access to the hardware node
- OpenVZ/Virtuozzo-based VPS environment
- VPS container ID available
- Basic knowledge of Linux command line
Checking Disk Space Usage
Run:
df -h
Example:
Filesystem Size Used Avail Use% Mounted on/dev/sda3 263G 212G 38G 86% /
The server may still have free disk space available.
Checking Inode Usage
Run:
df -i
Example:
Filesystem Inodes IUsed IFree IUse% Mounted on/dev/sda3 1008256 1008256 0 100% /
If IUse% is 100%, the inode limit has been exhausted.
Check VPS Quota Information
On the hardware node, check quota details:
cat /var/vzquota/quota.101
Replace 101 with your VPS container ID.
Important Configuration Files
/etc/sysconfig/vz/etc/sysconfig/vz-scripts/101.conf
Check VPS Filesystem Usage
vzctl exec 101 df -i
Increase Inode Limit
Increase Disk Space
vzctl set 101 --diskspace 1000000:1100000 --save
Increase Inode Value
vzctl set 101 --diskinodes 90000:91000 --save
Replace the values according to your requirements.
Verify VPS Quota Status
Run:
vzquota stat 101 -t
Conclusion
Inode exhaustion is a common issue in VPS containers hosting large numbers of files. By increasing the inode limits from the hardware node, you can resolve “Disk quota exceeded” errors even when sufficient disk space is available.
