[PVE-User] KVM vs Container - Why should one use KVM?
tony at zakula.com
Sat Nov 27 03:40:25 CET 2010
I am not familiar with Asterisk. Most of the issues arise from thread
and memory management. Java likes to ask the operating system how
much memory it has and then allocate accordingly. Sometimes, this
interferes with the container because the container isn't really
telling the truth. If you check out the OpenVZ site, there are
lengthy documents on how the memory management and thread management
takes place. You can run Java apps in a container, you just have to
know how to tune the container and the JVM. I have had trouble with
some Enterprise level apps like Sun Web Server, but that was again due
to the fact that it immediately wanted to open 100 threads and you
need to adjust the parameters of the container.
The only other thing I can advise on would be that if you use a
container for something critical, you need to learn to monitor the
container. There are command line utilities you can use to see when
memory, threads or other things have gone over their limits. It can
be more difficult to debug stressed apps that crash with a container.
If you do some Googling, you can find articles about this as well. A
heavily loaded container that runs out of memory many times will seem
like it is running fine and then just go off a cliff. With KVM, you
get basically the same thing you get with a bare metal machine. The
op system will start paging a lot and you can monitor it with any
tools you normally would with a bare metal machine and they will be
In summary, it always depends. I like and use both. It just depends
on the application.
On Fri, Nov 26, 2010 at 8:19 PM, Bruce B <bruceb444 at gmail.com> wrote:
> Thanks for the input Tony.
> Yeah, and those are the sort limitations that I would like to hear in a bit
> detail. Can you detail how the java misbehaves on a container?
> Also more importantly things that matter to Asterisk. For example sharing a
> timing source, etc...that relates to Asterisk.
> Any other limitations?
> On Fri, Nov 26, 2010 at 9:16 PM, Tony Zakula <tony at zakula.com> wrote:
>> The container works well for most things, but it is not a true virtual
>> machine. The KVM is a true virtual machine. If you are only running
>> Linux applications, the container will probably work fine, but there
>> are still some things like Java applications that require special care
>> to run in a container where it will run normally in a KVM.
>> Just my opinion.
>> Tony Z
>> On Fri, Nov 26, 2010 at 7:53 PM, Bruce B <bruceb444 at gmail.com> wrote:
>> > Hi Everyone,
>> > I have loaded a few KVM's and a few Container VMs. I don't like how the
>> > KVM
>> > shows using so much of the RAM. Comparison below:
>> > KVM = 3.22GB RAM
>> > CPU 2%
>> > VM = 16MB RAM
>> > CPU = 0%
>> > Both above are running CentOS and Asterisk. So, I am wondering why would
>> > anyone run in KVM mode? Are there any stability? reliability or
>> > limitations
>> > to Container VM that would restrain one from using a Container?
>> > Aside from limitations like one MUST run an .iso to install the OS, are
>> > there any other features that a container VM can't do that a KVM can do?
>> > Thanks
>> > _______________________________________________
>> > pve-user mailing list
>> > pve-user at pve.proxmox.com
>> > http://pve.proxmox.com/cgi-bin/mailman/listinfo/pve-user
More information about the pve-user