Answers: <p>While both Docker and jails have some similar functionality, they are built for different purposes.</p>
  
  <p>The term "jail" comes from the <a href="https://www.freebsd.org/doc/handbook/jails.html" rel="nofollow noreferrer">FreeBSD</a> distro.  A lot of people will also refer to a <a href="https://en.wikipedia.org/wiki/Chroot" rel="nofollow noreferrer">chroot</a> as a jail.  At its core these jails virtually change the root directory for a process and its children.  This means that these processes are contained (jailed) within this new directory and should not have access to folder outside of it.  Jails are a great way to run a process that you want isolated from the rest of the system.</p>
  
  <p>Docker Linux is an entire platform for running <a href="https://www.docker.com/resources/what-container" rel="nofollow noreferrer">containers</a>.  At its core it does this by using Linux namespaces and Linux Control Groups (<a href="https://livebook.manning.com/book/kubernetes-in-action/chapter-1/68" rel="nofollow noreferrer">source</a>).  Docker is built around packaging these containers and allowing them to easily be shared with other systems.</p>
  
  <p>Ultimately, both technologies are isolating processes.  However, Docker does this with the intent of making the isolated processes portable and repeatable.</p>
  
Answers: CC BY-SA 4.0
Answers: 2020-02-26T03:01:53.123Z
Answers: 2020-02-26T03:01:53.123Z
Answers: Wesley Rolnick
Body: <p>I am curious about difference between a jail environment in linux and Docker.  What separates these two technologies?</p>
  
Comments: CC BY-SA 4.0
Comments: 2020-02-24T17:16:33.387Z
Comments: Welcome to the DevOps Exchange.  Can you edit your question as right now it is extremely broad.  Here are some pointers: what research have you done?  What specific (instead of "all aspect") questions do you have?  Are you looking into something specific between the two?
Comments: Wesley Rolnick
Comments: CC BY-SA 4.0
Comments: 2020-02-25T08:13:14.597Z
Comments: Hi Wesley, I am newbie want only difference between jail env and container
Comments: Vishwanath
Tags: <docker><containers><linux><openshift><centos>
Title: What is the difference between a jail environment in linux and docker container?
UserDisplayName: Vishwanath
ThreadText: # What is the difference between a jail environment in linux and docker container?
  
  (Asked by: username_0 on 2020-02-24)
  
  I am curious about difference between a jail environment in linux and Docker. What separates these two technologies?
  
  **Tags:** docker, containers, linux, openshift, centos
  
  > **Comments:**
  > **username_1**: Welcome to the DevOps Exchange.  Can you edit your question as right now it is extremely broad.  Here are some pointers: what research have you done?  What specific (instead of "all aspect") questions do you have?  Are you looking into something specific between the two?  
  > **username_0**: Hi username_1, I am newbie want only difference between jail env and container  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2020-02-26. Score: 4
  
  While both Docker and jails have some similar functionality, they are built for different purposes.
  
  The term "jail" comes from the [FreeBSD](https://www.freebsd.org/doc/handbook/jails.html) distro. A lot of people will also refer to a [chroot](https://en.wikipedia.org/wiki/Chroot) as a jail. At its core these jails virtually change the root directory for a process and its children. This means that these processes are contained (jailed) within this new directory and should not have access to folder outside of it. Jails are a great way to run a process that you want isolated from the rest of the system.
  
  Docker Linux is an entire platform for running [containers](https://www.docker.com/resources/what-container). At its core it does this by using Linux namespaces and Linux Control Groups ([source](https://livebook.manning.com/book/kubernetes-in-action/chapter-1/68)). Docker is built around packaging these containers and allowing them to easily be shared with other systems.
  
  Ultimately, both technologies are isolating processes. However, Docker does this with the intent of making the isolated processes portable and repeatable.
  
  
  ---
  
  