Guide |
With the explosion of distributed, cloud computing, big data, a large number of cloud computing clusters appear, the computer hardware configuration can not be a higher, virtualization becomes one of the most core technology. Virtualization can be implemented either through hardware simulations or operating system levels, and in recent years the boom in container lightweight virtualization retains the mechanisms and features of the operating system itself, and Docker stands out. |
Docker's past life
Docker is a cloud open source project based on the Go language, which is now attributed to the Apache Foundation and complies with the Apache 2.0 protocol. Born in the beginning of 2013, the predecessor company for Dotcloud,docker Open Source has been widely concerned about the community, Docker ecosystem gradually matured, the company also renamed Docker Inc, focusing on docker related technology and product development.
The biggest goal of Docker is: "Build, ship and Run any App, anywhere! ”。 You can build and run your app from anywhere with just one package of application components. Whether it is a complete application, or some microservices, even to a complete operating system can become Docker's application components. Docker provides an efficient, agile, and lightweight container solution that dynamically adapts to system deployment requirements of all sizes.
The entire life cycle of Docker consists of three parts: Mirror (image), container (Container), Warehouse (Repository). Mirroring and container relationships are like programs and processes, mirroring is a precondition for a container to run, and a container is a running instance of mirroring. The warehouse is the central management of the image, and the default mirror warehouse is the Docker hub.
Docker needs to check if there is a corresponding mirror locally before running the container, and if it does not, try to download it from the default mirror repository. After mirroring is instantiated, a complete container is run, with the exception of the contents of the mirror itself, which provides an additional layer of writable files as well as a relatively separate runtime environment (perhaps some applications or services, or a complete operating system).
As a project of the C/S model, Docker manages mirroring, containers, daemons, partitions, and so on Docker host, while the Docker client is mirroring the pull, container building, and so on, usually the host and client are on the same machine.
Docker Open Source code address: Https://github.com/docker/docker
Docker's unique advantage
New deployment Methods
If there is one scenario: "A company's Web site project needs to be migrated to a new server because of business growth." In accordance with the traditional approach, we may well need to do some repetitive work. First, you need to install the corresponding operating environment on the new server and the corresponding dependencies, such as lamp (linux+apache+mysql+php), create the corresponding user or group and the management of file permissions, a lot of effort, the need to test the environment, and finally to deploy on-line. Imagine, if such a demand is more than 10 times times more, these jobs need to be executed repeatedly.
You might say that you can package the entire environment into a mirror and deploy it through virtualization, adding that the new server itself is also a virtualized machine, and a layer of Xen (or other virtual machines) to deploy is clearly superfluous.
Docker provides a very simple way to use containers to package applications, and we can package them in images or write dockerfile, which means that only the required containers can be started on the new server. This saves a lot of time and reduces the risk of problems with the deployment process.
the innovation of operation and maintenance strategy
1. Fast delivery and deployment
With Docker, developers can quickly build a standard set of development environments using mirroring. After the test and on-line link can be reused this set of images to deploy the application to the test environment or production environment anywhere. Docker can quickly create, delete, and maintain the configuration and operation of each step, reducing development, testing, deployment time, and making environment deployment easier to understand. With simple configuration file modifications, you can easily complete an iteration of a running environment, where all operations can be distributed and updated incrementally, enabling automated and efficient container management.
2. Low performance loss
In fact, Docker is a kernel-level virtualization that does not require an additional hypervisor, so unlocking the performance of Docker is almost negligible.
3. Portable and easy to move and expand
Docker is almost ready to run on any platform, whether it's a physical or virtualized host or even a PC compatible with Docker, a compatibility that makes it easier for applications to switch between running platforms.
4. Standard of standardization
The standard container execution engine behind Docker-Runc. Runc is an open industrialization standard followed by Docker contributions and its main content:
- Standardization of Operations : Container standardization operations include creating, starting, stopping containers using standard container sensations, copying and creating container snapshots using standard file system tools, and downloading and uploading using standardized network tools.
- Content -Independent: Content-independent means that the container standard operation can produce the same effect regardless of the specific container content. Containers can be uploaded and started in the same way, whether it is a PHP application or a MySQL database service.
- Infrastructure agnostic : Whether it's an individual laptop or AWS S3, or OpenStack, or any other infrastructure, it's all about supporting containers.
- tailor-made for automation : the establishment of a uniform standard of the container, is the operation of the content of irrelevant, platform-independent one of the fundamental purpose, is to enable the container operation of the entire platform automation.
- Industrial-grade delivery : The goal of setting a container standard is to make software distribution possible to achieve industrial-grade delivery.
5. Cluster Management
Kubernetes is the Google open-source Docker container Cluster Management system, which provides the whole set of functions of resource scheduling, deployment operation, service discovery, capacity expansion and so on for containerized applications, which can be regarded as the Mini-paas platform based on container technology in essence.
For a comparison of Docker and virtual machines, please refer to: http://www.linuxprobe.com/docker-and-vm.html
For Docker standards, please refer to: http://www.open-open.com/lib/view/open1444481959869.html
article section
The full text is mainly about the concept of Docker, presumably read here, Docker will no longer be a strange technology. Whether it's a management strategy for automated operations or PAAs for applications, Docker offers a great set of solutions, and Docker is a favorite in the field, giving operations an unprecedented quality experience. If you are also impressed by the charm of Docker, join the study of Docker to explore.
Docker's great way to go--first knowledge