In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
This article gives you an introduction to the running process of kubernetes cluster. Xiao Bian thinks it is quite practical, so share it for everyone to make a reference. Let's follow the editor and have a look.
Kubectl: k8s is a command line port used to send user commands.
Authorization
API (Programming Interface)
API server: (back) is the (front-end interface) of the k8s cluster. It is used by various client tools and other components of k8s to manage various resources of k8s cluster. He provides HTTP/HTTPS RESTful API, or K8S API.
Scheduler: Responsible for deciding on which node to run Pods on, taking into account the topology of the cluster, the current load of each node, and dealing with high availability, performance, data affinity, and demand.
Controller Manager: Responsible for managing the various resources of the cluster and ensuring that the resources are in the expected state. It consists of multiple Controllers, including Replication Controller. Endpoints Controller。Namespace Controller。Serviceaccounts Controller, etc.
Third-party components: He has alternatives. Consul,zookeeper。
Etcd: is responsible for saving configuration information of k8s cluster and status information of various resources. When data changes, etcd will quickly notify k8s related components.
**Pod: The smallest component unit of a k8s cluster. One pod can run one or more containers. In most cases, there is only one Container within a Pod.
Flannel: K8s cluster network solution, which can ensure cross-host communication of pods.
Third-party solutions, there are alternatives.
You can look at the IP address, and run on that node.
[root@master ~]# kubectl get pod --all-namespaces -o wide
Node:
Kubelet: It is the agent of the node. When the scheduler determines that a Pod is running on a Node, it will send the specific configuration information of the Pod to the kubelet of the node. The kubelet will create and run the container according to this information, and report the operation status to the Master.
kube-proxy: The container responsible for forwarding TCP/UDP traffic to the backend for access to the service. If there are multiple copies, kube-proxy implements Load Balancer.
Cadvisor: Control
//Run an example:
Create a deployment resource object,pod controller
kubectl run test-web --image=httpd --replicas=2
View:
[root@master ~]# kubectl get pod -o wide
[root@master ~]# kubectl get deployments.
Analyze the role of each component and the architecture workflow.
kubectl Send deployment request to API server
APIserver notifies Controller Manager to create a Deployment resource
Scheduler performs scheduling tasks, distributing two replica pods to node01 and node02
Kubelets on node01 and node2 create and run pods on their respective nodes.
Additional:
1. The configuration and current state information of the application is stored in etcd, and the API server reads this data from etcd by executing kubectl get pod.
2. Flannel assigns an IP to each Pod, but no Service resource is created at this time, so kube-proxy is not involved yet.
kubectl run test-web --image=httpd --replicas=2
kubectl get nodes
19 kubectl get deployments.
20 kubectl get pod
21 kubectl get pod -o wide
22 systemctl restart kubelet.service
23 kubectl get pod -o wide
24 kubectl delete pod test-web-5b56bdff65-fwp4l
26 kubectl get pod -o wide
2. Flannel aftertaste each pod assigned an ip, but at this time did not break into the ah service resources, kube-proxy has not yet participated in
The above is the detailed content of the Kubernetes cluster operation process. Is there any harvest after reading it? If you want to know more about it, welcome to pay attention to industry information!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.