最近更新时间:2024-09-14 10:54:54
CoreDNS支持通过Prometheus插件来采集指标,以便您能够更好地了解其运行状况。
在kce集群中,CoreDNS 已经配置了Prometheus插件,您可以通过以下方式访问指标数据:
端口: 默认为 9153
路径: /metrics
访问方式: 通过 <coredns podIP>:9153/metrics 获取指标,其中 <coredns podIP> 是CoreDNS Pod的IP地址。
除了标准的Go运行时指标外,CoreDNS 还提供了以下关键指标:
coredns_build_info{version, revision, goversion}- 版本信息
coredns_panics_total{}- Panic次数
coredns_dns_requests_total{server, zone, view, proto, family, type}- 查询总数
coredns_dns_request_duration_seconds{server, zone, view, type}- 查询耗时
coredns_dns_request_size_bytes{server, zone, view, proto}- 请求大小
coredns_dns_do_requests_total{server, view, zone}- DO位查询
coredns_dns_response_size_bytes{server, zone, view, proto}- 响应大小
coredns_dns_responses_total{server, zone, view, rcode, plugin}- 响应统计
coredns_dns_https_responses_total{server, status}- HTTPS响应
coredns_dns_quic_responses_total{server, status}- QUIC响应
coredns_plugin_enabled{server, zone, view, name}- 插件启用状态
有关指标的更多详细信息,请参阅CoreDNS Prometheus Metrics Plugin文档
纯净模式
