admin管理员组文章数量:1627750
Exploring what a running pod is
]# docker ps | grep pause
9220b8d70a54 k8s.gcr.io/pause:3.1 "/pause" 17 minutes ago Up 17 minutes k8s_POD_kubia-z92dc_default_cb20846a-706e-11e9-ba83-001e67d8acca_0
2c5420ea4edf k8s.gcr.io/pause:3.1 "/pause" 17 minutes ago Up 17 minutes k8s_POD_kubia-mf8dj_default_cb1f8b78-706e-11e9-ba83-001e67d8acca_0
This pause container is actually the container that holds all the containers of a pod together.
The pause container is actually an infrastructure container whose sole(唯一) purpose is to hold all these namespaces. All other user-defined containers of the pod then use the namespaces of the pod infrastructure container.
Figure: A two-container pod results in three running containers sharing the same Linux namespaces
Actual application containers may die and get restarted. When such a container starts up again, it needs to become part of the same namespaces as before. The infrastructure container makes this possible since its lifecycle is tied to that of the pod - the container runs from the time the pod is scheduled until the pod is deleted. If the infrastructure pod is killed in the meantime(在此期间), the Kubelet recreates it and all the pod’s containers.
本文标签: ampPodcontainerInfrastructure
版权声明:本文标题:Pod & Infrastructure container 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:https://www.elefans.com/dongtai/1729000741a1182565.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论