Dapr+Net6 服务调用09:集群指标收集-普罗米修斯
生活随笔
收集整理的這篇文章主要介紹了
Dapr+Net6 服务调用09:集群指标收集-普罗米修斯
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
1. 請參考上一篇文章創(chuàng)建基礎工程
Dapr+Net6 服務調用08:本地指標收集-普羅米修斯_敦格-CSDN博客Dapr+Net6 服務調用08:本地指標收集-普羅米修斯https://shuaihj.blog.csdn.net/article/details/122703624
2. 架構分析
Dapr?sidecar?公開指標收集終結點,Prometheus等收集器可通過此端點抓取指標。
3. 創(chuàng)建用于monitor的命名空間
kubectl create namespace dapr-monitoring4. 安裝普羅米修斯到集群
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts helm repo update helm install dapr-prom prometheus-community/prometheus -n dapr-monitoring --set nodeExporter.hostRootfs=false5. 驗證安裝結果
kubectl get pods -n dapr-monitoring6. 本地端口轉發(fā)到普羅米修斯
6.1.?獲取pod name
kubectl get pods --namespace dapr-monitoring -l "app=prometheus,component=server" -o jsonpath="{.items[0].metadata.name}"6.2. 端口轉發(fā)?
kubectl --namespace dapr-monitoring port-forward dapr-prom-prometheus-server-7b9fc57479-xwggq 90907. 通過普魯米修斯查看指標結果
7.1. 訪問service02應用
http://localhost:30001/api/hello7.2. 訪問普羅米修斯
http://localhost:9090/8. 故障排除
Error: failed to start container "node-exporter": Error response from daemon: path / is mounted on / but it is not a shared or slave mount解:helm install 命令最后增加參數?--set nodeExporter.hostRootfs=false
helm install dapr-prom prometheus-community/prometheus -n dapr-monitoring --set nodeExporter.hostRootfs=false總結
以上是生活随笔為你收集整理的Dapr+Net6 服务调用09:集群指标收集-普罗米修斯的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 战术板将要下岗 iPad登陆橄榄球场
- 下一篇: 医学计算机应用基础实验报告word,wo