Docker containers have their own kernel or not?











up vote
50
down vote

favorite
24












I see that a lot of docker images in the docker repository are made with an Ubuntu base.



What does that mean? Does each container bundle a stripped down version of the Linux kernel?



Do containers sit on top of their own kernels? But I thought containers share the kernel of the host (which in some cases is boot2docker, a custom Tiny Core Linux build, and in others something like CoreOS).



EDIT: Clarifying the question a bit. Yes I know docker is a process container, not a full VM. But since there are "Ubuntu" containers in the official docker hub registry and other OSes like CentOS, what does it mean to run Ubuntu in a container?



Answer: Ahh it just dawned on me. It is the Ubuntu user land processes, containing apt-get and other configuration processes for a particular Ubuntu build. Similarly for CentOS. Docker is not single process, just single entry. So for these distributions the entry point is some sort of init process that spawns other processes.










share|improve this question




















  • 2




    "It is the Ubuntu user land processes," - not only processes, but also libraries.
    – osgx
    Mar 14 '15 at 19:08















up vote
50
down vote

favorite
24












I see that a lot of docker images in the docker repository are made with an Ubuntu base.



What does that mean? Does each container bundle a stripped down version of the Linux kernel?



Do containers sit on top of their own kernels? But I thought containers share the kernel of the host (which in some cases is boot2docker, a custom Tiny Core Linux build, and in others something like CoreOS).



EDIT: Clarifying the question a bit. Yes I know docker is a process container, not a full VM. But since there are "Ubuntu" containers in the official docker hub registry and other OSes like CentOS, what does it mean to run Ubuntu in a container?



Answer: Ahh it just dawned on me. It is the Ubuntu user land processes, containing apt-get and other configuration processes for a particular Ubuntu build. Similarly for CentOS. Docker is not single process, just single entry. So for these distributions the entry point is some sort of init process that spawns other processes.










share|improve this question




















  • 2




    "It is the Ubuntu user land processes," - not only processes, but also libraries.
    – osgx
    Mar 14 '15 at 19:08













up vote
50
down vote

favorite
24









up vote
50
down vote

favorite
24






24





I see that a lot of docker images in the docker repository are made with an Ubuntu base.



What does that mean? Does each container bundle a stripped down version of the Linux kernel?



Do containers sit on top of their own kernels? But I thought containers share the kernel of the host (which in some cases is boot2docker, a custom Tiny Core Linux build, and in others something like CoreOS).



EDIT: Clarifying the question a bit. Yes I know docker is a process container, not a full VM. But since there are "Ubuntu" containers in the official docker hub registry and other OSes like CentOS, what does it mean to run Ubuntu in a container?



Answer: Ahh it just dawned on me. It is the Ubuntu user land processes, containing apt-get and other configuration processes for a particular Ubuntu build. Similarly for CentOS. Docker is not single process, just single entry. So for these distributions the entry point is some sort of init process that spawns other processes.










share|improve this question















I see that a lot of docker images in the docker repository are made with an Ubuntu base.



What does that mean? Does each container bundle a stripped down version of the Linux kernel?



Do containers sit on top of their own kernels? But I thought containers share the kernel of the host (which in some cases is boot2docker, a custom Tiny Core Linux build, and in others something like CoreOS).



EDIT: Clarifying the question a bit. Yes I know docker is a process container, not a full VM. But since there are "Ubuntu" containers in the official docker hub registry and other OSes like CentOS, what does it mean to run Ubuntu in a container?



Answer: Ahh it just dawned on me. It is the Ubuntu user land processes, containing apt-get and other configuration processes for a particular Ubuntu build. Similarly for CentOS. Docker is not single process, just single entry. So for these distributions the entry point is some sort of init process that spawns other processes.







docker






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Sep 28 '16 at 4:03









hippietrail

1,867113862




1,867113862










asked Mar 14 '15 at 6:17









stewart99

356135




356135








  • 2




    "It is the Ubuntu user land processes," - not only processes, but also libraries.
    – osgx
    Mar 14 '15 at 19:08














  • 2




    "It is the Ubuntu user land processes," - not only processes, but also libraries.
    – osgx
    Mar 14 '15 at 19:08








2




2




"It is the Ubuntu user land processes," - not only processes, but also libraries.
– osgx
Mar 14 '15 at 19:08




"It is the Ubuntu user land processes," - not only processes, but also libraries.
– osgx
Mar 14 '15 at 19:08










2 Answers
2






active

oldest

votes

















up vote
26
down vote













Docker uses host OS kernel, there is no custom or additional kernel inside container. All containers which run on a machine are sharing this "host" kernel.



Wikipedia says http://en.wikipedia.org/wiki/Docker_(software) that




Docker uses resource isolation features of the Linux kernel such as cgroups and kernel namespaces to allow independent "containers" to run within a single Linux instance, avoiding the overhead of starting virtual machines.




cgroups, namespaces and LXC are features of Linux kernel to isolate groups of processes; there is still single kernel, single scheduler, and one instance of kernel memory manager.



Boot2docker and CoreOS are just lightweight Linux distributions with some host kernel; they can be used to load Docker containers.



http://boot2docker.io/




boot2docker is a lightweight Linux distribution based on Tiny Core Linux made specifically to run Docker containers. It runs completely from RAM, weighs ~27MB and boots in ~5s (YMMV).




http://en.wikipedia.org/wiki/CoreOS




A single control host (CoreOS instance) runs multiple isolated Linux systems (containers), using Docker as an additional layer of abstraction and interface[14] to the underlying operating-system-level virtualization features of the Linux kernel. ... This approach relies on the Linux kernel's cgroups functionality, which provides namespace isolation and abilities to limit, account and isolate resource usage (CPU, memory, disk I/O, etc.) for the collections of processes.







share|improve this answer



















  • 1




    This doesn't answer the question.
    – EML
    Mar 26 '17 at 10:10






  • 2




    EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
    – osgx
    Mar 26 '17 at 14:00










  • sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
    – EML
    Mar 26 '17 at 14:50






  • 1




    EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
    – osgx
    Mar 26 '17 at 15:05


















up vote
10
down vote













In almost all cases, the host OS kernel is shared. To run a different kernel you need to use virtualization. This is rare and only used when necessary due to performance degradation.



"The Docker Engine container comprises just the application and its dependencies. It runs as an isolated process in userspace on the host operating system, sharing the kernel with other containers. Thus, it enjoys the resource isolation and allocation benefits of VMs but is much more portable and efficient."



This might help explain how it works:
enter image description here



Source: https://www.docker.com/whatisdocker/






share|improve this answer



















  • 4




    Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
    – osgx
    Mar 14 '15 at 6:46






  • 2




    What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
    – osgx
    Mar 14 '15 at 6:58






  • 1




    Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
    – JeremiahBarrar
    Mar 14 '15 at 7:40








  • 1




    JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
    – osgx
    Mar 14 '15 at 8:10






  • 2




    The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
    – user2707671
    Apr 13 at 13:36











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "3"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f889472%2fdocker-containers-have-their-own-kernel-or-not%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























2 Answers
2






active

oldest

votes








2 Answers
2






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
26
down vote













Docker uses host OS kernel, there is no custom or additional kernel inside container. All containers which run on a machine are sharing this "host" kernel.



Wikipedia says http://en.wikipedia.org/wiki/Docker_(software) that




Docker uses resource isolation features of the Linux kernel such as cgroups and kernel namespaces to allow independent "containers" to run within a single Linux instance, avoiding the overhead of starting virtual machines.




cgroups, namespaces and LXC are features of Linux kernel to isolate groups of processes; there is still single kernel, single scheduler, and one instance of kernel memory manager.



Boot2docker and CoreOS are just lightweight Linux distributions with some host kernel; they can be used to load Docker containers.



http://boot2docker.io/




boot2docker is a lightweight Linux distribution based on Tiny Core Linux made specifically to run Docker containers. It runs completely from RAM, weighs ~27MB and boots in ~5s (YMMV).




http://en.wikipedia.org/wiki/CoreOS




A single control host (CoreOS instance) runs multiple isolated Linux systems (containers), using Docker as an additional layer of abstraction and interface[14] to the underlying operating-system-level virtualization features of the Linux kernel. ... This approach relies on the Linux kernel's cgroups functionality, which provides namespace isolation and abilities to limit, account and isolate resource usage (CPU, memory, disk I/O, etc.) for the collections of processes.







share|improve this answer



















  • 1




    This doesn't answer the question.
    – EML
    Mar 26 '17 at 10:10






  • 2




    EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
    – osgx
    Mar 26 '17 at 14:00










  • sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
    – EML
    Mar 26 '17 at 14:50






  • 1




    EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
    – osgx
    Mar 26 '17 at 15:05















up vote
26
down vote













Docker uses host OS kernel, there is no custom or additional kernel inside container. All containers which run on a machine are sharing this "host" kernel.



Wikipedia says http://en.wikipedia.org/wiki/Docker_(software) that




Docker uses resource isolation features of the Linux kernel such as cgroups and kernel namespaces to allow independent "containers" to run within a single Linux instance, avoiding the overhead of starting virtual machines.




cgroups, namespaces and LXC are features of Linux kernel to isolate groups of processes; there is still single kernel, single scheduler, and one instance of kernel memory manager.



Boot2docker and CoreOS are just lightweight Linux distributions with some host kernel; they can be used to load Docker containers.



http://boot2docker.io/




boot2docker is a lightweight Linux distribution based on Tiny Core Linux made specifically to run Docker containers. It runs completely from RAM, weighs ~27MB and boots in ~5s (YMMV).




http://en.wikipedia.org/wiki/CoreOS




A single control host (CoreOS instance) runs multiple isolated Linux systems (containers), using Docker as an additional layer of abstraction and interface[14] to the underlying operating-system-level virtualization features of the Linux kernel. ... This approach relies on the Linux kernel's cgroups functionality, which provides namespace isolation and abilities to limit, account and isolate resource usage (CPU, memory, disk I/O, etc.) for the collections of processes.







share|improve this answer



















  • 1




    This doesn't answer the question.
    – EML
    Mar 26 '17 at 10:10






  • 2




    EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
    – osgx
    Mar 26 '17 at 14:00










  • sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
    – EML
    Mar 26 '17 at 14:50






  • 1




    EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
    – osgx
    Mar 26 '17 at 15:05













up vote
26
down vote










up vote
26
down vote









Docker uses host OS kernel, there is no custom or additional kernel inside container. All containers which run on a machine are sharing this "host" kernel.



Wikipedia says http://en.wikipedia.org/wiki/Docker_(software) that




Docker uses resource isolation features of the Linux kernel such as cgroups and kernel namespaces to allow independent "containers" to run within a single Linux instance, avoiding the overhead of starting virtual machines.




cgroups, namespaces and LXC are features of Linux kernel to isolate groups of processes; there is still single kernel, single scheduler, and one instance of kernel memory manager.



Boot2docker and CoreOS are just lightweight Linux distributions with some host kernel; they can be used to load Docker containers.



http://boot2docker.io/




boot2docker is a lightweight Linux distribution based on Tiny Core Linux made specifically to run Docker containers. It runs completely from RAM, weighs ~27MB and boots in ~5s (YMMV).




http://en.wikipedia.org/wiki/CoreOS




A single control host (CoreOS instance) runs multiple isolated Linux systems (containers), using Docker as an additional layer of abstraction and interface[14] to the underlying operating-system-level virtualization features of the Linux kernel. ... This approach relies on the Linux kernel's cgroups functionality, which provides namespace isolation and abilities to limit, account and isolate resource usage (CPU, memory, disk I/O, etc.) for the collections of processes.







share|improve this answer














Docker uses host OS kernel, there is no custom or additional kernel inside container. All containers which run on a machine are sharing this "host" kernel.



Wikipedia says http://en.wikipedia.org/wiki/Docker_(software) that




Docker uses resource isolation features of the Linux kernel such as cgroups and kernel namespaces to allow independent "containers" to run within a single Linux instance, avoiding the overhead of starting virtual machines.




cgroups, namespaces and LXC are features of Linux kernel to isolate groups of processes; there is still single kernel, single scheduler, and one instance of kernel memory manager.



Boot2docker and CoreOS are just lightweight Linux distributions with some host kernel; they can be used to load Docker containers.



http://boot2docker.io/




boot2docker is a lightweight Linux distribution based on Tiny Core Linux made specifically to run Docker containers. It runs completely from RAM, weighs ~27MB and boots in ~5s (YMMV).




http://en.wikipedia.org/wiki/CoreOS




A single control host (CoreOS instance) runs multiple isolated Linux systems (containers), using Docker as an additional layer of abstraction and interface[14] to the underlying operating-system-level virtualization features of the Linux kernel. ... This approach relies on the Linux kernel's cgroups functionality, which provides namespace isolation and abilities to limit, account and isolate resource usage (CPU, memory, disk I/O, etc.) for the collections of processes.








share|improve this answer














share|improve this answer



share|improve this answer








edited Jan 12 '16 at 22:46









Scott Stensland

259111




259111










answered Mar 14 '15 at 6:30









osgx

3,27954158




3,27954158








  • 1




    This doesn't answer the question.
    – EML
    Mar 26 '17 at 10:10






  • 2




    EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
    – osgx
    Mar 26 '17 at 14:00










  • sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
    – EML
    Mar 26 '17 at 14:50






  • 1




    EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
    – osgx
    Mar 26 '17 at 15:05














  • 1




    This doesn't answer the question.
    – EML
    Mar 26 '17 at 10:10






  • 2




    EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
    – osgx
    Mar 26 '17 at 14:00










  • sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
    – EML
    Mar 26 '17 at 14:50






  • 1




    EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
    – osgx
    Mar 26 '17 at 15:05








1




1




This doesn't answer the question.
– EML
Mar 26 '17 at 10:10




This doesn't answer the question.
– EML
Mar 26 '17 at 10:10




2




2




EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
– osgx
Mar 26 '17 at 14:00




EML, which question? By default all Docker containers have no own kernels. There is only one host kernel for all Docker containers.
– osgx
Mar 26 '17 at 14:00












sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
– EML
Mar 26 '17 at 14:50




sure, your answer is fine in as far as it goes, but the OP wanted to know why he must FROM a Ubuntu base image when the host is already running Ubuntu. To answer the question you have to explain what a base image is.
– EML
Mar 26 '17 at 14:50




1




1




EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
– osgx
Mar 26 '17 at 15:05




EML, the question was edited with "Clarifying"(superuser.com/posts/889472/revisions) after my answer had been posted, so it is answer to original question without clarification. If you have some information to share about base images and kernels in docker, add another answer.
– osgx
Mar 26 '17 at 15:05












up vote
10
down vote













In almost all cases, the host OS kernel is shared. To run a different kernel you need to use virtualization. This is rare and only used when necessary due to performance degradation.



"The Docker Engine container comprises just the application and its dependencies. It runs as an isolated process in userspace on the host operating system, sharing the kernel with other containers. Thus, it enjoys the resource isolation and allocation benefits of VMs but is much more portable and efficient."



This might help explain how it works:
enter image description here



Source: https://www.docker.com/whatisdocker/






share|improve this answer



















  • 4




    Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
    – osgx
    Mar 14 '15 at 6:46






  • 2




    What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
    – osgx
    Mar 14 '15 at 6:58






  • 1




    Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
    – JeremiahBarrar
    Mar 14 '15 at 7:40








  • 1




    JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
    – osgx
    Mar 14 '15 at 8:10






  • 2




    The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
    – user2707671
    Apr 13 at 13:36















up vote
10
down vote













In almost all cases, the host OS kernel is shared. To run a different kernel you need to use virtualization. This is rare and only used when necessary due to performance degradation.



"The Docker Engine container comprises just the application and its dependencies. It runs as an isolated process in userspace on the host operating system, sharing the kernel with other containers. Thus, it enjoys the resource isolation and allocation benefits of VMs but is much more portable and efficient."



This might help explain how it works:
enter image description here



Source: https://www.docker.com/whatisdocker/






share|improve this answer



















  • 4




    Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
    – osgx
    Mar 14 '15 at 6:46






  • 2




    What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
    – osgx
    Mar 14 '15 at 6:58






  • 1




    Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
    – JeremiahBarrar
    Mar 14 '15 at 7:40








  • 1




    JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
    – osgx
    Mar 14 '15 at 8:10






  • 2




    The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
    – user2707671
    Apr 13 at 13:36













up vote
10
down vote










up vote
10
down vote









In almost all cases, the host OS kernel is shared. To run a different kernel you need to use virtualization. This is rare and only used when necessary due to performance degradation.



"The Docker Engine container comprises just the application and its dependencies. It runs as an isolated process in userspace on the host operating system, sharing the kernel with other containers. Thus, it enjoys the resource isolation and allocation benefits of VMs but is much more portable and efficient."



This might help explain how it works:
enter image description here



Source: https://www.docker.com/whatisdocker/






share|improve this answer














In almost all cases, the host OS kernel is shared. To run a different kernel you need to use virtualization. This is rare and only used when necessary due to performance degradation.



"The Docker Engine container comprises just the application and its dependencies. It runs as an isolated process in userspace on the host operating system, sharing the kernel with other containers. Thus, it enjoys the resource isolation and allocation benefits of VMs but is much more portable and efficient."



This might help explain how it works:
enter image description here



Source: https://www.docker.com/whatisdocker/







share|improve this answer














share|improve this answer



share|improve this answer








edited Nov 29 at 14:50

























answered Mar 14 '15 at 6:30









JeremiahBarrar

407213




407213








  • 4




    Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
    – osgx
    Mar 14 '15 at 6:46






  • 2




    What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
    – osgx
    Mar 14 '15 at 6:58






  • 1




    Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
    – JeremiahBarrar
    Mar 14 '15 at 7:40








  • 1




    JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
    – osgx
    Mar 14 '15 at 8:10






  • 2




    The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
    – user2707671
    Apr 13 at 13:36














  • 4




    Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
    – osgx
    Mar 14 '15 at 6:46






  • 2




    What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
    – osgx
    Mar 14 '15 at 6:58






  • 1




    Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
    – JeremiahBarrar
    Mar 14 '15 at 7:40








  • 1




    JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
    – osgx
    Mar 14 '15 at 8:10






  • 2




    The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
    – user2707671
    Apr 13 at 13:36








4




4




Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
– osgx
Mar 14 '15 at 6:46




Any source for "Packages may use different kernels" ??? Docker itself can't use several kernels, there is always only single host kernel. Only when combined with hypervisor (virtualization) we can start several hosts each with own kernel version and run one Docker per virtual host; but for any host there will be only one kernel for host and for its Docked containers)
– osgx
Mar 14 '15 at 6:46




2




2




What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
– osgx
Mar 14 '15 at 6:58




What is package? Docker container has no kernel inside it; it just installed and started on the kernel which is used on the host. So: one Docker = one server = one kernel, just as shown in picture. No way to use two kernels with single Docker engine; all containers inside this engine will use same kernel. I think correct answer is "No, Docker containers can't use different kernels within single instance of Docker Engine"
– osgx
Mar 14 '15 at 6:58




1




1




Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
– JeremiahBarrar
Mar 14 '15 at 7:40






Each docker container can run whatever code it wants, including virtualization software that is able to load any kernel your software may require. You can run Windows in a container if you want to.
– JeremiahBarrar
Mar 14 '15 at 7:40






1




1




JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
– osgx
Mar 14 '15 at 8:10




JeremiahBarrar, Got it, thank you for explanation. Is running virtualization software from inside of Docker container documented and is it supported by Docker? What kind of virtualization will work from Docker (software qemu, qemu+kvm, xen,...)?
– osgx
Mar 14 '15 at 8:10




2




2




The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
– user2707671
Apr 13 at 13:36




The first sentence is misleading. Using a VM inside a container kind of defeats the point of using Docker.
– user2707671
Apr 13 at 13:36


















draft saved

draft discarded




















































Thanks for contributing an answer to Super User!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f889472%2fdocker-containers-have-their-own-kernel-or-not%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Plaza Victoria

In PowerPoint, is there a keyboard shortcut for bulleted / numbered list?

How to put 3 figures in Latex with 2 figures side by side and 1 below these side by side images but in...