问题描述
多集群可用性:在多集群场景下,监控系统的可用性、巨量存储及成本;
指标数据庞大:我们具有多个集群,导致集群 metrics 数量庞大,涉及 Promeheus 的性能以及高可用问题;
解决方案
系统架构
整体采用 thanos receiver + prometheus hashmod 的模式。
1)Prometheus hashmod 用于解决大体量集群的问题
2)Thanos receiver 适用于多集群场景
系统组件
1)Prometheus:prometheus 是基于指标的监控系统,云原生首选监控组件;
2)Alertmanager:alertmanager 主要用于接收 prometheus 发出的告警信息;
3)Grafana:grafana 是一个监控仪表系统,此方案中用于展示监控数据;
4)Thanos query:实现 Prometheus API,将来自下游组件提供的数据进行聚合,最终返回给查询数据的客户端 (如 grafana);
5)Thanos receiver:适配 prometheus 的 remote write API,将其数据提供给 thanos query 查询,并将其上传到对象存储;
6)Thanos store:将对象存储的数据暴露给 thanos query 去查询,缓存 TSDB 索引,优化对象存储的远程调用请求;
7)Thanos ruler:对监控数据进行评估和告警,还可以计算出新的监控数据,将这些新指标数据提供给 Thanos Query 查询,上传指标数据到对象存储,以供长期存储。
9)Thanos compact:将对象存储中的数据进行压缩和降低采样率,加速大时间区间监控数据查询的速度。
相关文章
Kubernetes Multi-Cluster Monitoring using Prometheus and Thanos | by VAIBHAV THAKUR | FAUN Publication
Kubernetes Multi-Cluster monitoring with Prometheus and Submariner | by Daniel Bachar | Medium
Monitoring Multiple Kubernetes Clusters | by Conor Nevin | THG Tech Blog | Medium
Multiple Kubernetes cluster monitoring with Prometheus | Sysrant
Create a Multi-Cluster Monitoring Dashboard with Thanos, Grafana and Prometheus | VMware Tanzu Developer Center
How to monitor multi-cloud Kubernetes with Prometheus and Grafana – Inlets – The Cloud Native Tunnel
Multi-Cluster Monitoring with Thanos