In daily work, sometimes we need to know the actual resource usage of each service in the current running cluster. In this case, we need Kubernetes cluster resource collection service Metrics-Server. Metrics-Server is used to collect the memory, disk, CPU, and network usage of Nodes and PODS.

Metrics – Server architecture diagram:

  

Metrics-server deployment

1. Download the resource file

B $git clone - release - 0.3 - https://github.com/kubernetes-incubator/metrics-server.gitCopy the code

2. Modify the configuration file

$CD metrics-server/deploy/1.8+/ $vim metrics-server-deployment.yamlCopy the code

The revised content is as follows:

---
apiVersion: v1
kind: ServiceAccount
meta
Copy the code