Linux Containers (LXC)- Another form of Virtualization

Govind Kumar
Sep 1, 2018 · 2 min read

Whenever we talk about computer nowadays, mostly we keep the term Servers at the top list of discussion. Thereafter, there is a proclivity towards Virtualization technology along with cloud computing. What if I tell that Virtualization or Cloud is not a technology? Yes, you read it correctly. Cloud or virtualization is not any technology in a true sense, these are ideas or concepts. There are certain technologies that allow virtualization in cloud computing to happen, we can use Hyper-V, Xen, ESXi for that. One of the things that we can use for that is something called as Linux Container.

I.T. industry emphasizes on the proper utilization of the resources, Virtualization gave the bolster to that demand by giving them the flexibility to run multiple Virtual Machines on top of a single host computer. While creating a virtual we reserve specific resources for that virtual machine. Suppose you have created 4 Virtual machines and allocated 2 Gb RAM to each of the Virtual Machines and the Service inside that virtual machine requires only half of the allocated resource. Don’t you think that even after using the Virtualization your resource is getting wasted? Linux Containers are the solution for that. Linux containers are an OS-level virtualization for providing multiple isolated Linux environments on a single Linux host. Unlike Virtual Machines, containers don’t run dedicated guest OS. Rather they share host OS Kernel and make use of guest OS libraries for providing the required OS capabilities. Containers make use of Linux Kernel features such as Namespaces, SELinux profile, chroots, CGroups for providing an isolated environment similar to VM. Let us try to understand this with an example: Suppose you need two Applications i.e LAMP and DNS Server and you are making use of the Linux container service for that. Here two containers will be created and both the containers will be accessing the resource directly from the physical host as per the requirement, after the completion of the task that server will not consume the resources and hence helping the other service to make use of the resource. Linux Containers are virtual machines without the hypervisor. The Daemon that is responsible for LXC is LXD(Linux Container Daemon).

Courtesy : Redhat

In the next series we will be doing hands on Linux Container and It’s comparison with Docker container.

Govind Kumar

Written by

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade