Top Reasons to pick KVM over OpenVZ


Staff member
I get this question a lot: should I choose openvz or KVM (linux based systems).

OpenVZ is a great virtualization environment and the most popular InterServer offers. If you are running a control panel like cpanel/WHM with a standard shared hosting set up, Openvz will be fine. Openvz has some features such as:

shared kernel (this also upgrades on the hostnode by ksplice automatically). The kernel security updates are done automatically for the kernel.

shared file system (no block device). Generally speaking OpenVZ IO will be faster.

Of course, some people want access to their own kernel, and perhaps want to set up LVM (requires a block device). In those cases KVM must be used.

After using both for so long here are some is the full list for reasons to choose KVM:

1) Java
If you are going to run a java program, like minecraft you want KVM so you do not run into memory issues. Openvz can have a tough time with Java programs due to the way memory is mapped.

2) Running a Samba server
You can't do this in OpenVZ (nor can you reliably do a samba mount).

3) Access to your own block device as mentioned above.

4) Kernel Access. On KVM you can compile your own kernel.

5) ISO access / Installing your own OS from an ISO. This can not be done on OpenVZ at all which is just template based. InterServer can set up a way for you to install your own ISO.

Keith Hinton

New Member
Also, I believe that KVM is similar to Xen.
The resources you get with KVM are guaranteed.
I am not so sure this holds true for Open VZ container-based virtualization.
like Xen, Swap partitions are completely supported in KVM where this is not so with Open VZ.
As for overhead, I believe that the overhead for running KVM is pretty small considering how long it's been around for so shouldn't be noticed.
Feel free to correct me on any of this.
Also, you get 100 percent isolation from any other vm using KVM, again, much like Xen.
Technically, also like Xen, KVM simulates it's own hardware-network card, etc, separate from that of the underlying server's hardware for any geek who cares about that type of thing.


Staff member
Under full virtualization Xen it is similar to KVM. KVM is more like a server. Real swap (using your disk space) is only available on KVM or Xen. Openvz now supports vswap, which free shows as swap but is artificially slower.

On interserver vps's resources for RAM are guaranteed for both openvz and kvm.

Keith Hinton

New Member
That's actually good to know, that resources are guaranteed regardless of the platform used to do the virtualization.
How does KVM handel server isolation in general compared to openVZ?
I have heard online before that something like OpenVZ does not isolate virtual machines from others on the system, increasing the chances of having other machines effect other virtual machines if one has a badly coded website, for instance, and that only KVM, Xen, and similar solutions do so.
Would you comment on that?


Staff member
The main difference is openvz is container based, meaning one kernel for all systems. Less OS's can run on openvz.

New features have been added to openvz for IO limits, improving the memory system - so really most of the complaints (except no kernel) are mute points now. Because of the single kernel openvz may be faster.

KVM allows windows to run because of kernel access. To make its speed more like "openvz" there virtio for disk / network are available our linux systems by default - not available yet on our window systems - and ksm runs to take duplicated memory and try to store them once.