"Kubectl proxy 통해 cadvisor 메트릭 조회"의 두 판 사이의 차이

(새 문서: ==개요== ;Kubectl proxy 통해 cadvisor 메트릭 조회 <syntaxhighlight lang='bash'> kubectl proxy & NODE=노드명 curl http://localhost:8001/api/v1/nodes/$NODE/proxy/metrics/ca...)
 
 
(같은 사용자의 중간 판 4개는 보이지 않습니다)
1번째 줄: 1번째 줄:
==개요==
==개요==
;Kubectl proxy 통해 cadvisor 메트릭 조회
{{소문자}}
;kubectl proxy 통해 cadvisor 메트릭 조회


<syntaxhighlight lang='bash'>
<syntaxhighlight lang='bash'>
kubectl proxy &
kubectl proxy &
NODE=노드명
NODE=노드명
curl http://localhost:8001/api/v1/nodes/$NODE/proxy/metrics/cadvisor
curl http://127.0.0.1:8001/api/v1/nodes/$NODE/proxy/metrics/cadvisor
pkill kubectl
</syntaxhighlight>
</syntaxhighlight>


16번째 줄: 18번째 줄:
</syntaxhighlight>
</syntaxhighlight>
<syntaxhighlight lang='console'>
<syntaxhighlight lang='console'>
controlplane $ kubectl proxy &
$ kubectl proxy &
[1] 5138
[1] 5138
controlplane $ Starting to serve on 127.0.0.1:8001
Starting to serve on 127.0.0.1:8001
</syntaxhighlight>
</syntaxhighlight>
<syntaxhighlight lang='console'>
<syntaxhighlight lang='console'>
$ NODE=node01
$ NODE=node01
$ curl http://localhost:8001/api/v1/nodes/$NODE/proxy/metrics/cadvisor  
$ curl http://127.0.0.1:8001/api/v1/nodes/$NODE/proxy/metrics/cadvisor  
...
...
# HELP machine_swap_bytes Amount of swap memory available on the machine.
# HELP machine_swap_bytes Amount of swap memory available on the machine.

2024년 9월 26일 (목) 16:50 기준 최신판

1 개요[ | ]

kubectl proxy 통해 cadvisor 메트릭 조회
Bash
Copy
kubectl proxy &
NODE=노드명
curl http://127.0.0.1:8001/api/v1/nodes/$NODE/proxy/metrics/cadvisor
pkill kubectl

2 실행예시[ | ]

Console
Copy
$ kubectl get no
NAME           STATUS   ROLES           AGE   VERSION
controlplane   Ready    control-plane   16d   v1.30.0
node01         Ready    <none>          16d   v1.30.0
Console
Copy
$ kubectl proxy &
[1] 5138
Starting to serve on 127.0.0.1:8001
Console
Copy
$ NODE=node01
$ curl http://127.0.0.1:8001/api/v1/nodes/$NODE/proxy/metrics/cadvisor 
...
# HELP machine_swap_bytes Amount of swap memory available on the machine.
# TYPE machine_swap_bytes gauge
machine_swap_bytes{boot_id="9780a0ea-9032-48c7-beb3-308732e2e5aa",machine_id="388a2d0f867a4404bc12a0093bd9ed8d",system_uuid="d727cefa-564a-43a0-8f5b-5f07eb547378"} 0
Console
Copy
$ pkill kubectl
[1]+  Terminated              kubectl proxy

3 같이 보기[ | ]

4 참고[ | ]