SlideShare ist ein Scribd-Unternehmen logo
1 von 33
Downloaden Sie, um offline zu lesen
1EMC CONFIDENTIAL—INTERNAL USE ONLY
Docker Introduction
Layne
2EMC CONFIDENTIAL—INTERNAL USE ONLY
$ uname -a
> No ops introduction
> No codes
> No Docker network (next time?)
> No Docker storage (Dockerone,
Vivian)
> One target: what is Docker?
> StarII program. Thanks for
being here.
3EMC CONFIDENTIAL—INTERNAL USE ONLY
$ ls –al ./
> $ man Docker
> $ man cgroup
> $ man namespaces
> User namespaces?
> Security your Docker
> $man UnionFS
> $man docker-layer
4EMC CONFIDENTIAL—INTERNAL USE ONLY
$ cat Docker
OS Virtualization
5EMC CONFIDENTIAL—INTERNAL USE ONLY
$ cat Docker
OS Virtualization
• Virtual machine emulates everything, including hardware
• Container isolates processes, users and filesystem.
6EMC CONFIDENTIAL—INTERNAL USE ONLY
$ cat Docker
LXC + Union FS
7EMC CONFIDENTIAL—INTERNAL USE ONLY
$ cat Docker
LXC + Union FS
cgroup + namespaces + Union FS
8EMC CONFIDENTIAL—INTERNAL USE ONLY
$ which Isolation
What is Isolation?
9EMC CONFIDENTIAL—INTERNAL USE ONLY
$ pstree -p
10EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man cgroup
• Limit, account, and isolate resource usage (CPU, memory, disk I/O, and more)
of process groups:
– Resource limiting: groups can be set to not exceed a set memory limit;
– Prioritization: some groups may get larger share of CPU or disk I/O
throughput;
– Accounting: to measure how much resource certain systems use;
– Control: freezing groups or checkpoint and restart
11EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man cgroup
12EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man cgroup
13EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man cgroup
Monitor resource inside a container?
Or: vmstat, iostat…
14EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man cgroup
Or: docker stats c7e8b77f5d84
15EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man namespaces
• UTS: isolate node-name and domain-name—returned by the uname()
system call
• Network: provide isolation of the system resources associated with
networking, including own network devices, IP addresses, IP routing tables,
/proc/net directory, port numbers, and so on.
• PID: isolate the process ID number space.
• Mount: isolate the set of filesystem mount points seen by a group of
processes. Thus, processes in different mount namespaces can have different
views of the filesystem hierarchy.
• IPC: isolate certain inter-process communication (IPC) resources, namely,
System V IPC objects and POSIX message queues.
• User: isolate the user and group ID number spaces. In other words, a
process's user and group IDs can be different inside and outside a user
namespace.
16EMC CONFIDENTIAL—INTERNAL USE ONLY
$ pstree -p
17EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man namespaces
docker run -it -m 256m --net=container:09f40c99ea5c
ubuntu:14.04 /bin/bash
18EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man namespaces
19EMC CONFIDENTIAL—INTERNAL USE ONLY
Network namespaces
20EMC CONFIDENTIAL—INTERNAL USE ONLY
Wait, why same host name?
21EMC CONFIDENTIAL—INTERNAL USE ONLY
Why say no User namespaces (yet)?
22EMC CONFIDENTIAL—INTERNAL USE ONLY
Why say no User namespaces (yet)?
ID-inside-ns ID-outside-ns length
23EMC CONFIDENTIAL—INTERNAL USE ONLY
Security your Docker
• No “--privileged=true”
• GID_Mapping/UID_Mapping with LXC driver;
• SELinux or AppArmor
• Libseccomp
• Capabilities
• ...
See: https://github.com/GDSSecurity/Docker-Secure-Deployment-Guidelines
24EMC CONFIDENTIAL—INTERNAL USE ONLY
Security your Docker
25EMC CONFIDENTIAL—INTERNAL USE ONLY
Conclusion of Isolation
–What is Isolation?
–Why we feel Docker is excellent?
26EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man UnionFS
It allows files and directories of separate file
systems, known as branches, to be
transparently overlaid, forming a single
coherent file system. Contents of directories
which have the same path within the
merged branches will be seen together in a
single merged directory, within the new,
virtual filesystem.
When mounting branches, the priority of
one branch over the other is specified. So
when both branches contain a file with the
same name, one gets priority over the other.
The different branches may be both read-only and read-write file systems, so that writes to the virtual,
merged copy are directed to a specific real file system. This allows a file system to appear as writable, but
without actually allowing writes to change the file system, also known as copy-on-write.
27EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man docker-layer
• Each layer of the FS is mounted on top of prior layers
• The first layer is the base image
• Current base images include debian, ubuntu, busybox,
fedora, cent os, etc
• Each read-only layer is called an image (A layer is just
a collection of files and folders!)
• The top layer is the only modifiable layer - it’s termed
the container
28EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man docker-layer
29EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man docker-layer
30EMC CONFIDENTIAL—INTERNAL USE ONLY
$ man docker-layer
31EMC CONFIDENTIAL—INTERNAL USE ONLY
$ (reverse-i-search)`cat': cat Docker
cgroup + namespaces + Union FS
32EMC CONFIDENTIAL—INTERNAL USE ONLY
$ ls -AF |grep '^.'
curl http://10.32.105.223/add_certs | sudo sh
(Only worked in Ubuntu currently)
Docker introduction

Weitere ähnliche Inhalte

Was ist angesagt?

Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9 Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9
Jérôme Petazzoni
 

Was ist angesagt? (20)

Introdution to Docker (theory and hands on) dbCafé - dbTrento
Introdution to Docker (theory and hands on) dbCafé - dbTrentoIntrodution to Docker (theory and hands on) dbCafé - dbTrento
Introdution to Docker (theory and hands on) dbCafé - dbTrento
 
What is Docker
What is DockerWhat is Docker
What is Docker
 
Introduction To Docker
Introduction To  DockerIntroduction To  Docker
Introduction To Docker
 
Docker and the Linux Kernel
Docker and the Linux KernelDocker and the Linux Kernel
Docker and the Linux Kernel
 
docker installation and basics
docker installation and basicsdocker installation and basics
docker installation and basics
 
Orchestrating Docker containers at scale
Orchestrating Docker containers at scaleOrchestrating Docker containers at scale
Orchestrating Docker containers at scale
 
Intro To Docker
Intro To DockerIntro To Docker
Intro To Docker
 
Docker Presentation
Docker PresentationDocker Presentation
Docker Presentation
 
Visualising Basic Concepts of Docker
Visualising Basic Concepts of Docker Visualising Basic Concepts of Docker
Visualising Basic Concepts of Docker
 
Docker Introduction
Docker IntroductionDocker Introduction
Docker Introduction
 
Tokyo OpenStack Summit 2015: Unraveling Docker Security
Tokyo OpenStack Summit 2015: Unraveling Docker SecurityTokyo OpenStack Summit 2015: Unraveling Docker Security
Tokyo OpenStack Summit 2015: Unraveling Docker Security
 
JOSA TechTalk: Introduction to docker
JOSA TechTalk: Introduction to dockerJOSA TechTalk: Introduction to docker
JOSA TechTalk: Introduction to docker
 
Docker
DockerDocker
Docker
 
Docker and the Container Ecosystem
Docker and the Container EcosystemDocker and the Container Ecosystem
Docker and the Container Ecosystem
 
Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9 Docker Introduction + what is new in 0.9
Docker Introduction + what is new in 0.9
 
Containers and docker
Containers and dockerContainers and docker
Containers and docker
 
Introduction to Docker
Introduction to DockerIntroduction to Docker
Introduction to Docker
 
Introduction to Docker
Introduction  to DockerIntroduction  to Docker
Introduction to Docker
 
Docker from A to Z, including Swarm and OCCS
Docker from A to Z, including Swarm and OCCSDocker from A to Z, including Swarm and OCCS
Docker from A to Z, including Swarm and OCCS
 
Introduction to Docker and deployment and Azure
Introduction to Docker and deployment and AzureIntroduction to Docker and deployment and Azure
Introduction to Docker and deployment and Azure
 

Andere mochten auch

2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
Fabio Fumarola
 

Andere mochten auch (8)

Docker Workshop Experten Forum Stuttgart 2015, Agile Methoden GmbH
Docker Workshop Experten Forum Stuttgart 2015, Agile Methoden GmbHDocker Workshop Experten Forum Stuttgart 2015, Agile Methoden GmbH
Docker Workshop Experten Forum Stuttgart 2015, Agile Methoden GmbH
 
WebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and DockerWebSphere Application Server Liberty Profile and Docker
WebSphere Application Server Liberty Profile and Docker
 
Introduction to Docker
Introduction to DockerIntroduction to Docker
Introduction to Docker
 
2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
 
Docker Networking
Docker NetworkingDocker Networking
Docker Networking
 
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
From VMs to Containers: Introducing Docker Containers for Linux and Windows S...
 
Cgroups, namespaces and beyond: what are containers made from?
Cgroups, namespaces and beyond: what are containers made from?Cgroups, namespaces and beyond: what are containers made from?
Cgroups, namespaces and beyond: what are containers made from?
 
Docker Einführung @GPN15
Docker Einführung @GPN15Docker Einführung @GPN15
Docker Einführung @GPN15
 

Ähnlich wie Docker introduction

Online Training in Unix Linux Shell Scripting in Hyderabad
Online Training in Unix Linux Shell Scripting in HyderabadOnline Training in Unix Linux Shell Scripting in Hyderabad
Online Training in Unix Linux Shell Scripting in Hyderabad
Ravikumar Nandigam
 
PowerPoint_merge.ppt on unix programming
PowerPoint_merge.ppt on unix programmingPowerPoint_merge.ppt on unix programming
PowerPoint_merge.ppt on unix programming
Priyadarshini648418
 
Inside Docker for Fedora20/RHEL7
Inside Docker for Fedora20/RHEL7Inside Docker for Fedora20/RHEL7
Inside Docker for Fedora20/RHEL7
Etsuji Nakai
 
Lamp ppt
Lamp pptLamp ppt
Lamp ppt
Reka
 

Ähnlich wie Docker introduction (20)

Docker: Aspects of Container Isolation
Docker: Aspects of Container IsolationDocker: Aspects of Container Isolation
Docker: Aspects of Container Isolation
 
The building blocks of docker.
The building blocks of docker.The building blocks of docker.
The building blocks of docker.
 
Online Training in Unix Linux Shell Scripting in Hyderabad
Online Training in Unix Linux Shell Scripting in HyderabadOnline Training in Unix Linux Shell Scripting in Hyderabad
Online Training in Unix Linux Shell Scripting in Hyderabad
 
Docker
Docker Docker
Docker
 
Lightweight Virtualization in Linux
Lightweight Virtualization in LinuxLightweight Virtualization in Linux
Lightweight Virtualization in Linux
 
Docker, Linux Containers, and Security: Does It Add Up?
Docker, Linux Containers, and Security: Does It Add Up?Docker, Linux Containers, and Security: Does It Add Up?
Docker, Linux Containers, and Security: Does It Add Up?
 
Docker, Linux Containers (LXC), and security
Docker, Linux Containers (LXC), and securityDocker, Linux Containers (LXC), and security
Docker, Linux Containers (LXC), and security
 
LXC NSAttach
LXC NSAttachLXC NSAttach
LXC NSAttach
 
Linux container, namespaces & CGroup.
Linux container, namespaces & CGroup. Linux container, namespaces & CGroup.
Linux container, namespaces & CGroup.
 
PowerPoint_merge.ppt on unix programming
PowerPoint_merge.ppt on unix programmingPowerPoint_merge.ppt on unix programming
PowerPoint_merge.ppt on unix programming
 
Cloud Native Computing - Part III - Containers
Cloud Native Computing - Part III - ContainersCloud Native Computing - Part III - Containers
Cloud Native Computing - Part III - Containers
 
Docker Security Overview
Docker Security OverviewDocker Security Overview
Docker Security Overview
 
Docker Dojo
Docker DojoDocker Dojo
Docker Dojo
 
Docker and kubernetes
Docker and kubernetesDocker and kubernetes
Docker and kubernetes
 
SW Docker Security
SW Docker SecuritySW Docker Security
SW Docker Security
 
Inside Docker for Fedora20/RHEL7
Inside Docker for Fedora20/RHEL7Inside Docker for Fedora20/RHEL7
Inside Docker for Fedora20/RHEL7
 
Unraveling Docker Security: Lessons From a Production Cloud
Unraveling Docker Security: Lessons From a Production CloudUnraveling Docker Security: Lessons From a Production Cloud
Unraveling Docker Security: Lessons From a Production Cloud
 
Linux for beginners
Linux for beginnersLinux for beginners
Linux for beginners
 
Lamp ppt
Lamp pptLamp ppt
Lamp ppt
 
Containers in depth – Understanding how containers work to better work with c...
Containers in depth – Understanding how containers work to better work with c...Containers in depth – Understanding how containers work to better work with c...
Containers in depth – Understanding how containers work to better work with c...
 

Kürzlich hochgeladen

+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
Health
 
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
masabamasaba
 

Kürzlich hochgeladen (20)

WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...
WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...
WSO2CON 2024 - Cloud Native Middleware: Domain-Driven Design, Cell-Based Arch...
 
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni%in Benoni+277-882-255-28 abortion pills for sale in Benoni
%in Benoni+277-882-255-28 abortion pills for sale in Benoni
 
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
WSO2CON 2024 - Building the API First Enterprise – Running an API Program, fr...
 
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
+971565801893>>SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHAB...
 
VTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learnVTU technical seminar 8Th Sem on Scikit-learn
VTU technical seminar 8Th Sem on Scikit-learn
 
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
Direct Style Effect Systems -The Print[A] Example- A Comprehension AidDirect Style Effect Systems -The Print[A] Example- A Comprehension Aid
Direct Style Effect Systems - The Print[A] Example - A Comprehension Aid
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
MarTech Trend 2024 Book : Marketing Technology Trends (2024 Edition) How Data...
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
 
%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand%in Midrand+277-882-255-28 abortion pills for sale in midrand
%in Midrand+277-882-255-28 abortion pills for sale in midrand
 
Artyushina_Guest lecture_YorkU CS May 2024.pptx
Artyushina_Guest lecture_YorkU CS May 2024.pptxArtyushina_Guest lecture_YorkU CS May 2024.pptx
Artyushina_Guest lecture_YorkU CS May 2024.pptx
 
Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...
Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...
Devoxx UK 2024 - Going serverless with Quarkus, GraalVM native images and AWS...
 
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
%in Rustenburg+277-882-255-28 abortion pills for sale in Rustenburg
 
WSO2Con2024 - Enabling Transactional System's Exponential Growth With Simplicity
WSO2Con2024 - Enabling Transactional System's Exponential Growth With SimplicityWSO2Con2024 - Enabling Transactional System's Exponential Growth With Simplicity
WSO2Con2024 - Enabling Transactional System's Exponential Growth With Simplicity
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
 
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
 
Announcing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK SoftwareAnnouncing Codolex 2.0 from GDK Software
Announcing Codolex 2.0 from GDK Software
 
WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...
WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...
WSO2CON 2024 - API Management Usage at La Poste and Its Impact on Business an...
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 

Docker introduction