Changes

Jump to: navigation, search

Resource shortage

1,407 bytes added, 09:59, 26 May 2006
Added disk quota operations
</pre>
If something is wrong, you need to fix it as suggested by the utility.
</li>
</ol>
 
== Disk quota ==
To check if your VE ran out of its disk quota, use the following commands (inside a VE):
<pre>
# df
Filesystem 1K-blocks Used Available Use% Mounted on
simfs 1048576 327664 720912 32% /
# df -i
Filesystem Inodes IUsed IFree IUse% Mounted on
simfs 200000 18857 181143 10% /
</pre>
 
First command shows disk space usage, and second command shows the inodes usage (you can roughly see inodes as a number of files/directories on your system).
 
If one of the commands give you usage of 100%, that means you hit one of the disk quota limit.
 
You can increase the limit from the host system ([[VE0]]) only. This is how:
<ol>
<li>Get the current values for disk quota:
<pre># vzquota stat 123
resource usage softlimit hardlimit grace
1k-blocks 327664 1048576 1153434
inodes 18857 200000 220000
</pre>
</li>
 
<li>To increase the disk space quota, use vzctl set --diskspace. For example, we want to increase it by a factor of 1.5:
<pre>
vzctl set 123 --diskspace $((1048576*1.5)):$((1153434*1.5)) --save
</pre>
</li>
 
<li>To increase the disk inodes quota, use <tt>vzctl set --diskinodes</tt>. For example, we want to increase it by a factor of 1.5:
<pre>
vzctl set 123 --diskinodes $((200000*1.5)):$((220000*1.5)) --save
</pre>
</li>
</ol>

Navigation menu