Yangming Kubernetes Advanced Training Camp

Basic Kubernetes interview questions

What is Kubernetes?

Answer: kubernetes is an open source container management tool, responsible for container deployment, scheduling, container scaling, and load balancing.

Specific functions:

Self-healing: Restart the failed container. When the node is unavailable, replace and reschedule the container on the node. The container that does not respond to the user-defined health check will be terminated and will not be sent to the customer until the container is ready for service End broadcast.

Elastic scaling: By monitoring the load value of the container's cpu, if the average value is higher than 80%, increase the number of containers, if it is lower than 10%, reduce the number of containers.

Automatic discovery and load balancing of services: kubernetes provides containers with unique IP addresses and a single dns name for a group of containers, and can load balance among them.

Rolling upgrade and one-click rollback: kubernetes

Gradually deploy changes to the application or its configuration while monitoring the application health to ensure that it does not terminate all instances at the same time. If something goes wrong, Kubernetes will revert the changes for you, leveraging the growing ecosystem of deployment solutions.

What is the relationship between Kubernetes and Docker?

Docker can build containers, but these containers communicate with each other across hosts through kubernetes. We can also use kubernetes to manually associate and orchestrate containers to run on multiple hosts.

What is the composition of Kubernetes?

kubectl: Client command line tool, as the operation entrance of the entire system.

kube-apiserver: Provides an interface in the form of REST API service as the control entrance of the entire system.

kube-conroller-manager: Perform background tasks for the entire system, including the status of nodes, the number of pods, and the association between pods and services.

kube-scheduler: Responsible for node resource management, receiving tasks from kube-apiserver to create pods, and assigning them to a node.

etcd: Service discovery and configuration sharing between replication nodes.

Kube-proxy: runs on each computing node, responsible for pod network proxy, and regularly obtains service information from etcd to make corresponding strategies.

Kubelet: runs on each computing node, as an agent, receives and distributes the pods task of the node and manages the container, periodically obtains the container status, and feeds it back to kube-apiserver

DNS: An optional DNS service used to create DNS records for each serivce object, so that all pods can access the service through DNS.

Guess you like

Origin blog.csdn.net/weixin_52772147/article/details/112343010