vmagent
Links
Title | URL |
---|---|
Targets | http://vmagent-host:8429/targets |
API Targets | http://vmagent-host:8429/api/v1/targets |
Service Discovery | http://vmagent-host:8429/service-discovery |
Logs
bash
{"ts":"2025-03-07T03:59:26.070Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/config.go:146","msg":"starting service discovery routines..."}
{"ts":"2025-03-07T03:59:26.070Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:607","msg":"started pod watcher for \"https://10.96.0.1:443/api/v1/pods\""}
{"ts":"2025-03-07T03:59:26.084Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:776","msg":"reloaded 30 objects from \"https://10.96.0.1:443/api/v1/pods?resourceVersion=0&resourceVersionMatch=NotOlderThan\" in 0.015s; updated=0, removed=0, added=30, resourceVersion=\"518003\""}
{"ts":"2025-03-07T03:59:26.084Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:607","msg":"started service watcher for \"https://10.96.0.1:443/api/v1/services\""}
{"ts":"2025-03-07T03:59:26.088Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:776","msg":"reloaded 23 objects from \"https://10.96.0.1:443/api/v1/services?resourceVersion=0&resourceVersionMatch=NotOlderThan\" in 0.004s; updated=0, removed=0, added=23, resourceVersion=\"517916\""}
{"ts":"2025-03-07T03:59:26.088Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:607","msg":"started endpoints watcher for \"https://10.96.0.1:443/api/v1/endpoints\""}
{"ts":"2025-03-07T03:59:26.093Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:776","msg":"reloaded 25 objects from \"https://10.96.0.1:443/api/v1/endpoints?resourceVersion=0&resourceVersionMatch=NotOlderThan\" in 0.005s; updated=0, removed=0, added=25, resourceVersion=\"517996\""}
{"ts":"2025-03-07T03:59:26.093Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:607","msg":"started node watcher for \"https://10.96.0.1:443/api/v1/nodes\""}
{"ts":"2025-03-07T03:59:26.096Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:776","msg":"reloaded 1 objects from \"https://10.96.0.1:443/api/v1/nodes?resourceVersion=0&resourceVersionMatch=NotOlderThan\" in 0.003s; updated=0, removed=0, added=1, resourceVersion=\"517973\""}
{"ts":"2025-03-07T03:59:26.096Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:607","msg":"started endpointslice watcher for \"https://10.96.0.1:443/apis/discovery.k8s.io/v1/endpointslices\""}
{"ts":"2025-03-07T03:59:26.101Z","level":"info","caller":"VictoriaMetrics/lib/promscrape/discovery/kubernetes/api_watcher.go:776","msg":"reloaded 23 objects from \"https://10.96.0.1:443/apis/discovery.k8s.io/v1/endpointslices?resourceVersion=0&resourceVersionMatch=NotOlderThan\" in 0.004s; updated=0, removed=0, added=23, resourceVersion=\"517970\""}
bash
成功发现并监控 Kubernetes 资源:
发现了 30 个 pods
发现了 23 个 services
发现了 25 个 endpoints
发现了 1 个 node
发现了 23 个 endpointslices