kubernetes 1.16+ simple metrics-server

Jbn1233
Oct 30, 2020

--

Download the latest components.yaml from below link:

Since metrics-server communicates by node host name, So I need hostAliases

add this hostAliases and kubelet-insecure-tls args to components.yaml

hostAliases:
- hostnames:
- s160
ip: 192.19.14.160
- hostnames:
- s161
ip: 192.19.14.161
- hostnames:
- s162
ip: 192.19.14.162

kubectl apply -f components.yaml and wait for~15 min.

$ kubectl top node
NAME CPU(cores) CPU% MEMORY(bytes) MEMORY%
s160 176m 4% 744Mi 19%
s161 44m 1% 273Mi 7%
s162 37m 0% 326Mi 8%

Done.

--

--

Jbn1233
Jbn1233

Written by Jbn1233

Very short and simple notes for CKA/SRE and may not works on your environment | jbn1233@gmail.com | Bangkok, Thailand |

No responses yet