docker study notes -03: Mirror of principle docker

Mirroring is a lightweight, standalone executable software package used to package software operating environment and software-based operating environment developed. It contains everything you need to run an environment that includes code libraries, environment variables and configuration files.

First, what is a mirror

(A), a joint file system (UnionFS):

  1, the file system is the basis docker combined mirror is a layered, lightweight and high-performance file system that supports changes to the file system as a first submitted to superimposed layers.

  Feature 2, the joint file system: load multiple files at one time systems, but from the looks of it, only to see a file system. United will load the file system layers stack up, so that the final document will contain all the directories and files.

  3, docker inheritance may be performed by layering, on the base image, can produce a variety of specific applications image.

(Two), mirroring load principle:

  1, docker mirror actually is composed of one layer of the file system, the file system is hierarchical such combined file system

  2, docker bottom-up consists of two levels: bootfs and rootfs.

  3, bootfs (boot file system) is the mirror image of the bottom docker, mainly containing bootloader and Kernel, and corresponds to the linux kernel linux kernel loader. After bootfs loaded memory usage to the kernel, the system will unload bootfs.

  4, rootfs (root file system) is different linux operating system releases, such as ubuntu and centos. Above rootfs, a typical system linux / dev, / etc, / bin and other directories and files. rootfs can be small, common core to the host.

  5. Why take the mirror hierarchy: in order to share resources. There are multiple mirrors are built from the same base image, then save a copy of the host as long as the base image on disk, and memory only need to load a base image, you can assume that all the container services.

 

Second, the characteristics of the mirror

  1, docker image are read-only.

  2, when a container starts a new write can be loaded into the top layer of the mirror, and this layer is usually called "the container layer" below "the container layer" are called "mirror structure."

Guess you like

Origin www.cnblogs.com/Luv-GEM/p/11490791.html