SlideShare une entreprise Scribd logo
1  sur  15
Linux Containers
What's Linux Containers?
Linux Containers(LXC) allow running multiple isolated Linux instances
(containers) on the same host.
Containers share the same kernel with anything else that is running on it, but
can be constrained to only use a defined amount of resources such as CPU,
memory or I/O.
A container is a way to isolate a group of processes from the others on a
running Linux system.
Why Linux Containers?
 Provision in seconds / milliseconds
 Near bare metal runtime performance
 VM-like agility – it’s still “virtualization”
 Flexibility
• Containerize a “system”
• Containerize “application(s)”
 Lightweight
• Just enough Operating System (JeOS)
• Minimal per container penalty
Growing in popularity
Virtual Network Types
LXC containers support the following networking types:
• empty - creates only loopback interface and assigns it to the container.
• vlan - a vlan interface is linked with the interface specified in container's
configuration and is assigned to a the container.
• phys - an already existing interface is assigned to the container. This is useful
when you want to assign a physical network interface to a LXC container.
• none - will cause container to use host's network namespace.
Terminology in LXC
• Chroot :
A change root (chroot, or change root jail) is a section in the file system which
is isolated from the rest of the file system. For this purpose, the chroot command is used
to change the root of the file system.
• Cgroups :
Kernel Control Groups (commonly referred to as just “cgroups”) are a Kernel
feature that allows aggregating or partitioning tasks (processes) and all their children into
hierarchical organized groups to isolate resources.
• Container :
A “virtual machine” on the host server that can run any Linux system, for
example openSUSE, SUSE Linux Enterprise Desktop, or SUSE Linux Enterprise Server.
Terminology Continued...
• Container Name :
A name that refers to a container. The name is used by the lxc commands.
• Kernel Namespaces :
A Kernel feature to isolate some resources like network, users, and others for a
group of processes.
• LXC Host Server :
The system that contains the LXC system and provides the containers and
management control capabilities through cgroups.
Hypervisors vs. Linux
Containers
Hardware
Operating System
Hypervisor
Virtual Machine
Operating
System
Bins / libs
Ap
p
Ap
p
Virtual Machine
Operating
System
Bins / libs
Ap
p
Ap
p
Hardware
Hypervisor
Virtual Machine
Operating
System
Bins / libs
Ap
p
Ap
p
Virtual Machine
Operating
System
Bins / libs
Ap
p
Ap
p
Hardware
Operating System
Container
Bins / libs
Ap
p
Ap
p
Container
Bins / libs
Ap
p
Ap
p
Type 1 Hypervisor Type 2 Hypervisor Linux Containers
Containers are isolated,
but share OS and,
where appropriate, libs /
bins.
Docker vs. LXC vs. Hypervisor
Docker: LXC Virtualization?
Docker decouples the LXC provider from the operations
• LXC provider agnostic
Docker “images” run anywhere docker is supported
• Portability
Who’s Using LXC
Google app engine & infra is said to be using some form of LXC
RedHat OpenShift
dotCloud (now docker inc)
CloudFoundry (early versions)
Rackspace Cloud Databases
Parallels Virtuozzo (commercial product)
LXC Gaps
There are gaps…
•Lack of industry tooling / support
•Full orchestration across resources (compute / storage / networking)
•Fears of security
•Not a well known technology… yet
•Integration with existing virtualization and Cloud tooling
•Not much / any industry standards
•Missing skillset
•Slower upstream support due to kernel dev process
LXC: Use Cases For Traditional VMs
There are still use cases where traditional VMs are warranted.
•Virtualization of non Linux based OSs
•Windows
•AIX
•LXC not supported on host
•VM requires unique kernel setup which is not applicable to other VMs on
the host (i.e. per VM kernel config)
Features Of Linux Containers
Lightweight and resource – friendly
Comprehensive process and resource isolation
Run multiple versions of an operating system on a single server
Rapid and Easy deployment
Advantages
Easier maintenance and backup of individual virtual machines than one 'big'
linux server
Running different 'servers' on one physical computer saves hardware and
power costs
Security separation, hardware access from inside a vm may be restricted
Disadvantages
Speed issues if too many vm's are using the same hardware at the same time
(especially hard drive access, recommend a SSD).
If hardware breaks, all virtual machines machines are affected.
Might have problems accessing hardware, as access to that hardware might
be restricted.

Contenu connexe

Tendances

Tendances (20)

Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes Introduction
 
Container Security
Container SecurityContainer Security
Container Security
 
Virtualization with KVM (Kernel-based Virtual Machine)
Virtualization with KVM (Kernel-based Virtual Machine)Virtualization with KVM (Kernel-based Virtual Machine)
Virtualization with KVM (Kernel-based Virtual Machine)
 
Containers: The What, Why, and How
Containers: The What, Why, and HowContainers: The What, Why, and How
Containers: The What, Why, and How
 
Linux container, namespaces & CGroup.
Linux container, namespaces & CGroup. Linux container, namespaces & CGroup.
Linux container, namespaces & CGroup.
 
presentation on Docker
presentation on Dockerpresentation on Docker
presentation on Docker
 
Containers and Docker
Containers and DockerContainers and Docker
Containers and Docker
 
Red Hat multi-cluster management & what's new in OpenShift
Red Hat multi-cluster management & what's new in OpenShiftRed Hat multi-cluster management & what's new in OpenShift
Red Hat multi-cluster management & what's new in OpenShift
 
Kubernetes 101 for Beginners
Kubernetes 101 for BeginnersKubernetes 101 for Beginners
Kubernetes 101 for Beginners
 
Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes Introduction
 
Rancher 2.0 Technical Deep Dive
Rancher 2.0 Technical Deep DiveRancher 2.0 Technical Deep Dive
Rancher 2.0 Technical Deep Dive
 
Containerization is more than the new Virtualization: enabling separation of ...
Containerization is more than the new Virtualization: enabling separation of ...Containerization is more than the new Virtualization: enabling separation of ...
Containerization is more than the new Virtualization: enabling separation of ...
 
Hands-on Helm
Hands-on Helm Hands-on Helm
Hands-on Helm
 
Ansible presentation
Ansible presentationAnsible presentation
Ansible presentation
 
Kubernetes Introduction
Kubernetes IntroductionKubernetes Introduction
Kubernetes Introduction
 
Podman rootless containers
Podman rootless containersPodman rootless containers
Podman rootless containers
 
Kubernetes 101 - an Introduction to Containers, Kubernetes, and OpenShift
Kubernetes 101 - an Introduction to Containers, Kubernetes, and OpenShiftKubernetes 101 - an Introduction to Containers, Kubernetes, and OpenShift
Kubernetes 101 - an Introduction to Containers, Kubernetes, and OpenShift
 
Ansible Automation Platform.pdf
Ansible Automation Platform.pdfAnsible Automation Platform.pdf
Ansible Automation Platform.pdf
 
Deep dive into Kubernetes Networking
Deep dive into Kubernetes NetworkingDeep dive into Kubernetes Networking
Deep dive into Kubernetes Networking
 
Kubernetes - introduction
Kubernetes - introductionKubernetes - introduction
Kubernetes - introduction
 

Similaire à Introduction to linux containers

Similaire à Introduction to linux containers (20)

Containers - Cloud Phoenix March Meetup
Containers - Cloud Phoenix March MeetupContainers - Cloud Phoenix March Meetup
Containers - Cloud Phoenix March Meetup
 
Linux Container Brief for IEEE WG P2302
Linux Container Brief for IEEE WG P2302Linux Container Brief for IEEE WG P2302
Linux Container Brief for IEEE WG P2302
 
Lightweight Virtualization in Linux
Lightweight Virtualization in LinuxLightweight Virtualization in Linux
Lightweight Virtualization in Linux
 
Evolution of containers to kubernetes
Evolution of containers to kubernetesEvolution of containers to kubernetes
Evolution of containers to kubernetes
 
Realizing Linux Containers (LXC)
Realizing Linux Containers (LXC)Realizing Linux Containers (LXC)
Realizing Linux Containers (LXC)
 
Understanding the container landscape and it associated projects
Understanding the container landscape and it associated projectsUnderstanding the container landscape and it associated projects
Understanding the container landscape and it associated projects
 
Docker Dojo
Docker DojoDocker Dojo
Docker Dojo
 
20240201 [HPC Containers] Rootless Containers.pdf
20240201 [HPC Containers] Rootless Containers.pdf20240201 [HPC Containers] Rootless Containers.pdf
20240201 [HPC Containers] Rootless Containers.pdf
 
An Updated Performance Comparison of Virtual Machines and Linux Containers
An Updated Performance Comparison of Virtual Machines and Linux ContainersAn Updated Performance Comparison of Virtual Machines and Linux Containers
An Updated Performance Comparison of Virtual Machines and Linux Containers
 
OpenVZ Linux Containers
OpenVZ Linux ContainersOpenVZ Linux Containers
OpenVZ Linux Containers
 
Deploying Apache CloudStack from API to UI
Deploying Apache CloudStack from API to UIDeploying Apache CloudStack from API to UI
Deploying Apache CloudStack from API to UI
 
OpenNebulaConf2017EU: Hyper converged infrastructure with OpenNebula and Ceph...
OpenNebulaConf2017EU: Hyper converged infrastructure with OpenNebula and Ceph...OpenNebulaConf2017EU: Hyper converged infrastructure with OpenNebula and Ceph...
OpenNebulaConf2017EU: Hyper converged infrastructure with OpenNebula and Ceph...
 
paper
paperpaper
paper
 
Apache CloudStack from API to UI
Apache CloudStack from API to UIApache CloudStack from API to UI
Apache CloudStack from API to UI
 
Linux virtualization
Linux virtualizationLinux virtualization
Linux virtualization
 
Apache CloudStack: API to UI (STLLUG)
Apache CloudStack: API to UI (STLLUG)Apache CloudStack: API to UI (STLLUG)
Apache CloudStack: API to UI (STLLUG)
 
Containers and workload security an overview
Containers and workload security an overview Containers and workload security an overview
Containers and workload security an overview
 
Txlf2012
Txlf2012Txlf2012
Txlf2012
 
Introduction to OS LEVEL Virtualization & Containers
Introduction to OS LEVEL Virtualization & ContainersIntroduction to OS LEVEL Virtualization & Containers
Introduction to OS LEVEL Virtualization & Containers
 
SW Docker Security
SW Docker SecuritySW Docker Security
SW Docker Security
 

Dernier

Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
dharasingh5698
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ssuser89054b
 
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoorTop Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
dharasingh5698
 
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 

Dernier (20)

VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
VIP Model Call Girls Kothrud ( Pune ) Call ON 8005736733 Starting From 5K to ...
 
Double Revolving field theory-how the rotor develops torque
Double Revolving field theory-how the rotor develops torqueDouble Revolving field theory-how the rotor develops torque
Double Revolving field theory-how the rotor develops torque
 
Call Girls Wakad Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Wakad Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Wakad Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Wakad Call Me 7737669865 Budget Friendly No Advance Booking
 
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance BookingCall Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
Call Girls Walvekar Nagar Call Me 7737669865 Budget Friendly No Advance Booking
 
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar  ≼🔝 Delhi door step de...
Call Now ≽ 9953056974 ≼🔝 Call Girls In New Ashok Nagar ≼🔝 Delhi door step de...
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdf
 
data_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdfdata_management_and _data_science_cheat_sheet.pdf
data_management_and _data_science_cheat_sheet.pdf
 
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
(INDIRA) Call Girl Bhosari Call Now 8617697112 Bhosari Escorts 24x7
 
Unit 1 - Soil Classification and Compaction.pdf
Unit 1 - Soil Classification and Compaction.pdfUnit 1 - Soil Classification and Compaction.pdf
Unit 1 - Soil Classification and Compaction.pdf
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Palanpur 7001035870 Whatsapp Number, 24/07 Booking
 
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
 
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank  Design by Working Stress - IS Method.pdfIntze Overhead Water Tank  Design by Working Stress - IS Method.pdf
Intze Overhead Water Tank Design by Working Stress - IS Method.pdf
 
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoorTop Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
Top Rated Call Girls In chittoor 📱 {7001035870} VIP Escorts chittoor
 
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...Booking open Available Pune Call Girls Koregaon Park  6297143586 Call Hot Ind...
Booking open Available Pune Call Girls Koregaon Park 6297143586 Call Hot Ind...
 
Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01Double rodded leveling 1 pdf activity 01
Double rodded leveling 1 pdf activity 01
 
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort ServiceCall Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
Call Girls in Netaji Nagar, Delhi 💯 Call Us 🔝9953056974 🔝 Escort Service
 
Thermal Engineering Unit - I & II . ppt
Thermal Engineering  Unit - I & II . pptThermal Engineering  Unit - I & II . ppt
Thermal Engineering Unit - I & II . ppt
 
chapter 5.pptx: drainage and irrigation engineering
chapter 5.pptx: drainage and irrigation engineeringchapter 5.pptx: drainage and irrigation engineering
chapter 5.pptx: drainage and irrigation engineering
 
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced LoadsFEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
FEA Based Level 3 Assessment of Deformed Tanks with Fluid Induced Loads
 

Introduction to linux containers

  • 2. What's Linux Containers? Linux Containers(LXC) allow running multiple isolated Linux instances (containers) on the same host. Containers share the same kernel with anything else that is running on it, but can be constrained to only use a defined amount of resources such as CPU, memory or I/O. A container is a way to isolate a group of processes from the others on a running Linux system.
  • 3. Why Linux Containers?  Provision in seconds / milliseconds  Near bare metal runtime performance  VM-like agility – it’s still “virtualization”  Flexibility • Containerize a “system” • Containerize “application(s)”  Lightweight • Just enough Operating System (JeOS) • Minimal per container penalty Growing in popularity
  • 4. Virtual Network Types LXC containers support the following networking types: • empty - creates only loopback interface and assigns it to the container. • vlan - a vlan interface is linked with the interface specified in container's configuration and is assigned to a the container. • phys - an already existing interface is assigned to the container. This is useful when you want to assign a physical network interface to a LXC container. • none - will cause container to use host's network namespace.
  • 5. Terminology in LXC • Chroot : A change root (chroot, or change root jail) is a section in the file system which is isolated from the rest of the file system. For this purpose, the chroot command is used to change the root of the file system. • Cgroups : Kernel Control Groups (commonly referred to as just “cgroups”) are a Kernel feature that allows aggregating or partitioning tasks (processes) and all their children into hierarchical organized groups to isolate resources. • Container : A “virtual machine” on the host server that can run any Linux system, for example openSUSE, SUSE Linux Enterprise Desktop, or SUSE Linux Enterprise Server.
  • 6. Terminology Continued... • Container Name : A name that refers to a container. The name is used by the lxc commands. • Kernel Namespaces : A Kernel feature to isolate some resources like network, users, and others for a group of processes. • LXC Host Server : The system that contains the LXC system and provides the containers and management control capabilities through cgroups.
  • 7. Hypervisors vs. Linux Containers Hardware Operating System Hypervisor Virtual Machine Operating System Bins / libs Ap p Ap p Virtual Machine Operating System Bins / libs Ap p Ap p Hardware Hypervisor Virtual Machine Operating System Bins / libs Ap p Ap p Virtual Machine Operating System Bins / libs Ap p Ap p Hardware Operating System Container Bins / libs Ap p Ap p Container Bins / libs Ap p Ap p Type 1 Hypervisor Type 2 Hypervisor Linux Containers Containers are isolated, but share OS and, where appropriate, libs / bins.
  • 8. Docker vs. LXC vs. Hypervisor
  • 9. Docker: LXC Virtualization? Docker decouples the LXC provider from the operations • LXC provider agnostic Docker “images” run anywhere docker is supported • Portability
  • 10. Who’s Using LXC Google app engine & infra is said to be using some form of LXC RedHat OpenShift dotCloud (now docker inc) CloudFoundry (early versions) Rackspace Cloud Databases Parallels Virtuozzo (commercial product)
  • 11. LXC Gaps There are gaps… •Lack of industry tooling / support •Full orchestration across resources (compute / storage / networking) •Fears of security •Not a well known technology… yet •Integration with existing virtualization and Cloud tooling •Not much / any industry standards •Missing skillset •Slower upstream support due to kernel dev process
  • 12. LXC: Use Cases For Traditional VMs There are still use cases where traditional VMs are warranted. •Virtualization of non Linux based OSs •Windows •AIX •LXC not supported on host •VM requires unique kernel setup which is not applicable to other VMs on the host (i.e. per VM kernel config)
  • 13. Features Of Linux Containers Lightweight and resource – friendly Comprehensive process and resource isolation Run multiple versions of an operating system on a single server Rapid and Easy deployment
  • 14. Advantages Easier maintenance and backup of individual virtual machines than one 'big' linux server Running different 'servers' on one physical computer saves hardware and power costs Security separation, hardware access from inside a vm may be restricted
  • 15. Disadvantages Speed issues if too many vm's are using the same hardware at the same time (especially hard drive access, recommend a SSD). If hardware breaks, all virtual machines machines are affected. Might have problems accessing hardware, as access to that hardware might be restricted.