Linux container-based virtualization with OpenVZ

April 4, 2010 — 6 Comments

Long time since my last post. I’ve been on holidays! :-D

But don’t worry my dear readers, I did not fall into laziness and the few times I wasn’t playing with my son I’ve been playing in my homelab with other virtualization technologies, storage appliances, my ESXi servers… what can I say I’m a Geek. One of the most interesting technologies I’ve been playing with is OpenVZ.

OpenVZ is a container-based operating system-level virtualization technology for Linux, if you have ever worked with Solaris 10 Zones this is very similar. The OpenVZ project is supported by Parallels which also have based their commercial solution Virtuozzo on OpenVZ.

OpenVZ (and other container-based technologies) differs with other technologies like VMware or HPVM in that the last ones virtualize the entire machine with its own OS, disks, ram, etc. OpenVZ on the contrary use only one Linux kernel and create multiple isolated instances. of course there are pros and cons, just to name a couple:

  • VMware, HPVM and other true hypervisors are more flexible since many different operative systems can be run on top of them, OpenVZ on the contrary can only run Linux instances.
  • OpenVZ since it is not a real hypervisor does not have their overhead so it is very fast.

Glossary of terms:

  • Host node, CTo, VEo: The host where the containers run.
  • VPS, VE: The containers themselves. One Host node can run multiple VPS and each VPS can run a different Linux distribution such as Gentoo, Ubuntu, CentOS, etc, but every VPS operate under the same Linux kernel.
  • CTID: ConTainer’s IDentifier. A unique number that every VPS has and used to manage it.
  • Beancounters: The beancounters, also known as UBC Parameter Units, are nothing but a set of limits defined by the system administrator. The beancounters assure that no VPS can abuse the resources of the Host node. The whole list of Beancounter is described in detail in the OpenVZ wiki.
  • VPS templates: The templates are the images used to create new containers.

OpenVZ directory structure:

  • /vz – The default main directory.
  • /vz/private – Where the VPS are stored.
  • /vz/template/cache – In this path are stored the templates for the different Linux distributions.
  • /etc/vz – Configuration directory for OpenVZ.
  • /etc/vz/vz.conf – OpenVZ configuration file.

Resource management:

The amount of resources from the Host node available for the Virtual Environments can be managed through four different ways.

  • Two-Level Disk Quota: The administrator of the Host node can set-up disk quotas for each  container.
  • Fair CPU scheduler: It is a two-level scheduler with a first level scheduler deciding which container is given the CPU time slice and on the second level the standard Linux scheduler decides which process to run in that container.
  • I/O scheduler: Very similar to the CPU scheduler, is also a two-level scheduler. Priorities are assigned to each container and the I/O scheduler distributes the available bandwidth according to those priorities.
  • User Beancounters.

I’m now in the process of set-up an OpenVZ test server in my homelab so I will try to cover some of its features more in depth in a future post.

Juanma.

Advertisements

6 responses to Linux container-based virtualization with OpenVZ

  1. 

    Hi Team ,

    With a single intention to promote Linux open source technology to the best of our nature , LinuxPune.com team has decided to request Linux Based Bloggers to send us their respective unique article with their pictures in our mail id info@linuxpune.com which will be posted in our blog section and interns we will also request your respective team to post our link hence we can mutually help each other to increase the bacllinks .

    Hope its going to be a fantastic associated we are looking forward to ….

    LinuxPune Team
    http://linuxpune.com
    info@linuxpune.com
    Linux Training Pune | Linux Migration | Linux Placement | Cloud Implementation | Outsourcing

  2. 

    In order to work 50 weeks a year, you’re going to have to work 30 weeks; in order to work 30 weeks, you’ll likely have to work 10.
    For more information on my Workshops, Writing Mastermind Groups and private coaching,
    please go to my website listed below and feel free to call me any time.

    Whether these are taken live – while you are doing a real gig – or whether you have them done on a false stage, will depend on you.

Trackbacks and Pingbacks:

  1. Linux container-based virtualization with OpenVZ « Juanma's Blog | Linux Affinity - April 4, 2010

    […] more from the original source: Linux container-based virtualization with OpenVZ « Juanma's Blog Posted in: Kernels ADD […]

  2. Linux container-based virtualization with OpenVZ « Juanma's Blog | VirtualizationDir - Top Virtualization Providers, News and Resources - April 5, 2010

    […] original post here: Linux container-based virtualization with OpenVZ « Juanma's Blog Plurk This Post Delicious Digg This Post MySpace Ping This Post Reddit This Post […]

  3. Tweets that mention Linux container-based virtualization with OpenVZ « Juanma's Blog -- Topsy.com - April 14, 2010

    […] This post was mentioned on Twitter by Larry King. Larry King said: Linux container-based virtualization with OpenVZ « Juanma's Blog http://bit.ly/9O65Jp #Linux […]

  4. Migrating Virtuozzo to OpenVZ or SolusVM! | Linux Admins - October 15, 2011

    […] = 'none'; document.getElementById('singlemouse').style.display = ''; } Linux container-based virtualization with OpenVZMigration from Parallels Virtuozzo to SolusVMOpenVPN Internet Routing on OpenVZ VPSHyperVM […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s