KVM and OpenVZ Virtualization provides the option to overcommit the physical memory. Most of the Memory assigned to a VPS is not being utilized fully and the remaining memory can be made free for other VPS.
Memory Overcommit option is only available for KVM and OpenVZ.
If your dedicated server has 15GB memory, without memory overcommit, you can create 15 VPS of 1GB each. In this scenario if all the VPS is only utilizing 200MB of 1 GB assigned, then all the remaining 800MB from 15 VPS will not be utilized and left in the server.
Instead of wasting 800×15 = ~11GB, you can create new VPS with that remaining space. For Overcommiting the memory, you need to follow the below steps.
To enable the memory overcommit, you need to update the memory limit in the configuration.
Go to Configuration > Slave Settings > RAM Overcommit
And set your required memory limit.
- Memory overcommit depends upon the existing VPS utilization and free memory available in the server. We recommend to set the memory limit with respect to the memory utilized by all the VPS available (or will be created) in the server.
- The server host on which you want to overcommit RAM must have sufficient SWAP space present.