Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to understand the Docker container host and container operating system for Linux and Windows containers

2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

How to understand the Docker container host and container operating system for Linux and Windows containers? in view of this problem, this article introduces the corresponding analysis and solutions in detail, hoping to help more partners who want to solve this problem to find a more simple and feasible method.

Let's explore the relationship between the container host and the container operating system, and the difference between Linux and Windows containers.

Some definitions

Container host: also known as the host operating system. The host operating system is the operating system on which Docker clients and Docker daemons run. In the case of Linux and non-Hyper-V containers, the host operating system shares the kernel with the running Docker container. For Hyper-V, each container has its own Hyper-V kernel.

Container operating system: also known as the base operating system. A base operating system is an image that contains an operating system such as Ubuntu, CentOS, or windowsservercore. Typically, you will build your own image on top of the underlying operating system image so that you can take advantage of some of the operating system's features. Note that the Windows container requires a base operating system, while the Linux container does not.

Operating system kernel: the kernel manages underlying functions such as memory, file system, network, and process scheduling.

Some of the following pictures

Linux Containers

In the above example:

The host operating system is Ubuntu.

The Docker client and the Docker daemon (together known as the Docker engine) are running on the host operating system.

Each container shares the host operating system kernel.

CentOS and BusyBox are the basic operating system images of Linux.

The "No OS" container indicates that you do not need the underlying operating system to run a container in Linux. You can create a Docker file that contains the basic image of scratch, and then run the binaries that directly use the kernel.

Check out this article to compare the size of the basic OS.

Windows Containers-Non Hyper-V

In the above example:

The host operating system is Windows 10 or Windows Server.

Each container shares the host operating system kernel.

All Windows containers require the underlying operating system of nanoserver or windowsservercore.

Windows Containers-Hyper-V

In the above example:

The host operating system is Windows 10 or Windows Server.

Each container is hosted in its own lightweight Hyper-V virtual machine.

Each container uses a kernel within the Hyper-V virtual machine, which provides an additional layer of separation between containers.

All Windows containers require the underlying operating system of nanoserver or windowsservercore.

A few good links

About Windows Container

Implement Windows containers in depth, including multi-user mode and "copy-on-write" to save resources

How Linux containers save resources by using copy-on-write

This is the answer to the question about how to understand the Docker container host and container operating system for Linux and Windows containers. I hope the above content can be of some help to you. If you still have a lot of doubts to be solved, you can follow the industry information channel for more related knowledge.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report