Step 1: Execute kubectl top nodes in the kubernetes. If you are not able to view the below details then execute Step 2 otherwise go to Step 3.
Step 2: Install metrics pod in the Kubernetes. Execute the the below command to install metrics pod.
kubectl apply -f https://github.com/kubernetes-sigs/metrics-server/releases/latest/download/components.yaml
Check if the metrics server is running by executing the below command.
kubectl get pods -n kube-system
Note: If it is running then go to Step 3. If it is not running then follow the below steps
1: Edit the configuration file by executing the below command.
kubectl edit deployments.apps -n kube-system metrics-server
2: Add the below lines in the spec: container: args: and save the file.
3: After few minutes execute the command kubectl get pods -n kube-system and check the metrics server is running. If it is running skip the below step.
4: Edit the configuration file by executing the command kubectl edit deployments.apps -n kube-system metrics-server and modify the below lines in the spec: container: args: and save it.
5: To verify the metrics API server is running execute the below command and check
kubectl top nodes
SingleAgent should be deployed in the machine where kubernetes cluster is running.
Step 3: Refer here to install SingleAgent and start.
Once we start the agent it will be added to Applicare Console.
Step 4. Execute the below command and note down the cluster server details for configuration.
kubectl config view
Cluster IP : kubernetes.docker.internal
Port : 6443
Protocol : https
Step 5: Login into Applicare console and go to Overview screen and select the newly added server and click Edit button.
Step 6: Enable the Add Kubernetes Monitoring checkbox and add the configuration details. Leave the Token field empty and click the update button.
Steps to Edit and delete the existing Kubernetes configuration.
Go to Overview Screen
For update select the server and click edit and update the details and save.
For delete uncheck the Add the Kubernetes Monitoring checkbox and click update.
Go to Kubernetes Screen
For update select the row and click Edit and update the details and click Save button.
For delete select the row and click Delete button.