Slashdot Mirror


Performance Evaluation of Xen Vs. OpenVZ

An anonymous reader writes "Compared to an operating-system-level virtualization technology like OpenVZ, Xen — a hypervisor-level virtualization technology that allows multiple operating systems to be run with and without para-virtualization — trades off performance for much better isolation and security. OpenVZ's performance advantage due to running virtual containers in a single operating system kernel can be significant. A performance evaluation study (PDF) done by researchers at the University of Michigan and HP labs provides insight into how big a performance penalty Zen pays and what causes the overheads (primarily L2 cache misses)." From the report: "We compare both technologies with a base system in terms of application performance, resource consumption, scalability, low-level system metrics like cache misses and virtualization-specific metrics like Domain-0 consumption in Xen. Our experiments indicate that the average response time can increase by over 400% in Xen and only a modest 100% in OpenVZ as the number of application instances grows from one to four... A similar trend is observed in CPU consumptions of virtual containers."

10 of 116 comments (clear)

  1. Oblig. Nonsensical reference by jd · · Score: 5, Funny
    how big a performance penalty Zen pays

    Zen's performance issues were fixed by Avon, under Orac's guidance.

    --
    It's a small world and it smells funny; I'd buy another if it wasn't for the money; Take back what I paid (SoM)
  2. Both are good. by Blackknight · · Score: 4, Informative

    As somebody that actually has experience setting up and running virtualized systems (I work for a web hosting company) let me add my two cents here.

    OpenVZ is ok if all of your child environments run the same OS and you don't care about them stealing each other's resources. We constantly have problems with customers overloading their VPS and causing problems with the other environments, this doesn't happen with Xen. I've fork bombed child environments and caused the load to spike to over 700 until it crashed, dom0 and the rest of my domUs just kept running like nothing was even happening.

    OpenVZ also wins if you want to oversell hardware, Xen doesn't have "burstable" memory like OpenVZ does. Personally I prefer Xen for the jailing that it does and you can also run multiple OSes at the same time. I have a server at work that's running CentOS, Windows 2003, Windows Longhorn, and Gentoo all at the same time, OpenVZ only lets you run Linux on Linux.

    1. Re:Both are good. by flydpnkrtn · · Score: 5, Informative

      When you sit down and do your homework, and don't oversell as you said, OpenVZ gets the job done. I was looking for a good way of virtualizing a new server we were moving to and I've gotta say I can't see myself ever NOT installing a server in either an OpenVZ VE or a Xen domU ever again.... with OpenVZ you can give one VE (almost) all the resources of the hardware its running on, and when that one server outgrows that hardware doing a vzdump or vzmigrate is sooo easy.

      The big difference between Xen and OpenVZ comes down to what openvz calls "privvmpages" - memory that is claimed by running processes but not actually used.

      The example here is this: two OpenVZ virtual environments (VE) can be set up on a server with, say, 1 gig of ram, with a gig of swap underneath it (So, RAM+Swap equals 2 gigs).

      Those two virtual environments can be "oversold" in the amount of privvmpages they're allowed to use, because processes ask for more memory than they _actually use_ all the time. So let's say we give those two VEs 1.5 gigs of privvmpages (total of 3 gigs - more than RAM+Swap), but we only give them each 500 megs of oomguarpages. (less than RAM+Swap).

      The thing that _should never_ go over RAM+Swap is oomguarpages (out of memory guaranteed pages) - pages of memory that are guaranteed (OpenVZ measures some of its resources in pages and some in megs).

      With Xen, on that server I just described you're locked in - there's no bursting, and there's no dynamic allocation going on. You give one domU 750 megs of ram and you give the other domU 750. That's it.

  3. Yes, but ... by Anonymous Coward · · Score: 4, Funny

    Does it run multiple instances of Linux?

  4. And... by coyote4til7 · · Score: 5, Insightful

    Nothing like a virtualization comparison that ignores the 800 guerilla that is VMWare. How do the learning curves, performance and security of these products compare with VMWare? Why should someone who is satisfied with VMWare consider other alternatives?

    --

    the clock on the wall says 4 til 7
    1. Re:And... by coyote4til7 · · Score: 4, Insightful

      Good point.

      Do I get a Karma bonus for conceding someone's point? ;-)

      --

      the clock on the wall says 4 til 7
  5. Xen vs VMware - personal experience by Anonymous Coward · · Score: 5, Informative

    Here are a few talking points based on my experiences with both Xen and VMWare (ESX Server & Workstation).

    1. Cost - no contest, xen wins hands down $0 vs $5000/cpu.
    2. Performance - xen wins noticably, i can get away with running 8 virtual machines with 1/4 the hardware that VMWare required for 6.
    3. Capabilities - VMware versions ESX GSX and up beat Xen in ease of use and flexibility, anything less and Xen wins. Xen does have a quicker live migration capability, but falls short on conencting external hardware to the virtual machine (something that is trivial in VMware).
    4. Stability - about even, maybe Xen. I've seen ESX crash once, and have never seen Xen crash.
    5. Ease of use - VMWare no question. Theres a learning curve to Xen and setting up new VM images is a pain. (which is disappearing) There are fantastic tools for VMware that will let you manage virtual machine creation and even migration from a physical box. (some of which can be used to feed xen too =))

    The bottom line. A Xen setup (using open source version) that can easily run 12 VMs costs about $2,000 on DIY hardware. A VMWare server/software combo to do the same? about $30,000. Assume an additional 40-80 hours of learning to get up to speed with Xen vs VMware.

    The comments above cover the open source / free version of Xen. I have no experience with the commercial Xen offerings.

    Personally i'm Xen biased due to cost.

  6. Re:Stop the press by jambarama · · Score: 4, Insightful

    Yeah but Xen is still a royal PITA to get running. KVM wasn't bad, and VMWare was pretty easy. I haven't even seen OpenVZ. Of the three I've tried, the ease of use was highly correlated to the product maturity. All three work, but IMHO VMWare is so far ahead it will take some time for Xen to be considered out of the hobbyist market and in the commercial one. I'm sure it'll get there, but to do what? Be a faster VMWare?

    So to sum, we've got OpenVZ, Virtualbox, KVM/Qemu, Xen, VMWare, Virtual Iron, and Virtuozzo. With so much virtualization software, I personally think performance takes a back seat to functionality (sure OpenVZ is fast, cool, what will it do for me that VMWare or Xen won't?). Is there really that much space in the virtualization landscape?

  7. It's not always about performance by cerberusss · · Score: 4, Informative

    It's not always about performance; Xen gets each their separate kernel. This means that special adjustments can be made for a virtual machine. Also, with Xen you could easily experiment with an upgraded kernel for the virtual machines, without rebooting the main (host) machine. Finally, I for myself like the fact that you have your 'own' kernel. It feels much more like a real machine. Especially with a bootloader like pygrub, which is employed in RedHat AS and CentOS, the kernel inside the virtual machine can even be upgraded by yum running inside the VM.

    Note that I'm not a Xen apologist, I'm not denying a performance hit here.

    --
    8 of 13 people found this answer helpful. Did you?
  8. Re:Stop the press by Xouba · · Score: 4, Interesting

    Yeah but Xen is still a royal PITA to get running. KVM wasn't bad, and VMWare was pretty easy. I haven't even seen OpenVZ.

    Yes, Xen is harder to install. But to compare it with KVM ... did you try to use them? KVM (at least, last time I tried -- which was only a couple weeks ago) is still in development, and the performance is so low compared to Xen that it's not even funny.

    On the other hand, VMware is very nice, specially the free Server edition, and it's really easy to use. But even so, performance is better in Xen. Check this. Paravirtualization needs modified guests, but the outcome is so good that VMware is trying paravirtualization too.

    VMWare is so far ahead it will take some time for Xen to be considered out of the hobbyist market and in the commercial one

    What do you think is needed for Xen to be considered apt for commercial use? Remember that Xen can use unmodified guests if the hardware supports VTX/SVM instructions, which means that it can run Windows. Pretty front-ends? Xensource (which is slashdotted now, I guess, because it times out from here) offers one, and you also have Enomalism.

    Besides, by what Wikipedia says about OpenVZ, it seems to be more a solution like jails, because it uses the same kernel for both the host and the guest systems. The phrase "glorified chroot" comes to mind, though I'm aware that it's more than that (just adding it for the sake of trolling, I guess :-)). Xen, VMware and QEMU/KVM are, on the other hand, real virtualization solutions, where all the virtual system runs completely isolated.

    I wouldn't recommend Xen for home use (VMware Server is a better and easier option, IMHO), but saying that it's not ready and comparing it to QEMU/KVM is almost a joke.