Monitor 组件容量规划

Monitor 组件负责存储从平台中一个或多个集群收集的指标数据。因此,您需要提前评估您的 monitor 规模,并根据本文档中的指导规划 monitor 组件所需的资源。

目录

假设与方法论

  • 本文档中的数据来自受控实验室性能报告,旨在作为生产规划的容量基线。
  • 磁盘示例的保留时间为 7 天;其他保留目标请按比例调整。
  • 存储基线符合上述警告(SSD,约 6000 IOPS,约 250MB/s 读写,独立挂载)。
  • 测试工作负载涵盖了典型的监控页面,如“acp ns overview page”和“platform region detail page”。

Prometheus

以下是 Prometheus 及相关组件(Thanos Query、Thanos Sidecar 等)按规模的容量建议。

小规模 — 10 个 worker 节点,500 个双容器 Pod

  • 指标摄取速率:约 2800 samples/秒
ComponentContainerReplicasCPU LimitMemory LimitDisk (if applicable)Notes
courier-apicourier22C4Gi--
kube-prometheus-thanos-querythanos-query11C1Gi--
prometheus-kube-prometheus-0prometheus12C8Gi20G7 天内约 10G 写入

中等规模 — 50 个 worker 节点,2000 个双容器 Pod

  • 指标摄取速率:约 7294 samples/秒
ComponentContainerReplicasCPU LimitMemory LimitDisk (if applicable)Notes
courier-apicourier24C4Gi--
kube-prometheus-thanos-querythanos-query12.5C8Gi--
prometheus-kube-prometheus-0prometheus14C8Gi40G7 天内约 30G 写入

大规模 — 500 个 worker 节点,10000 个双容器 Pod

  • 指标摄取速率:约 41575 samples/秒
ComponentContainerReplicasCPU LimitMemory LimitDisk (if applicable)Notes
courier-apicourier26C4Gi--
kube-prometheus-thanos-querythanos-query12C6Gi-现场部署可能使用 2 个副本
prometheus-kube-prometheus-0prometheus18C20Gi100G峰值内存约 15Gi;7 天内约 69G 写入

VictoriaMetrics

以下是 VictoriaMetrics 组件按规模的容量建议。

小规模 — 10 个 worker 节点,500 个双容器 Pod

  • 指标摄取速率:约 3274 samples/秒
ComponentContainerReplicasCPU LimitMemory LimitDisk (if applicable)Notes
courier-apicourier12C4Gi--
vmselect-clusterproxy11C200Mi--
vmselectvmselect1500m1Gi--
vmstorage-clustervmstorage1500m2Gi3G7 天内约 1.5G 写入

中等规模 — 50 个 worker 节点,2000 个双容器 Pod

  • 指标摄取速率:约 6940 samples/秒
ComponentContainerReplicasCPU LimitMemory LimitDisk (if applicable)Notes
courier-apicourier24C4Gi--
vmselect-clusterproxy11C200Mi--
vmselectvmselect12C2Gi--
vmstorage-clustervmstorage12C2Gi10G7 天内约 2.6G 写入

大规模 — 500 个 worker 节点,10000 个双容器 Pod

  • 指标摄取速率:约 34300 samples/秒
ComponentContainerReplicasCPU LimitMemory LimitDisk (if applicable)Notes
courier-apicourier26C4Gi--
vmselect-clusterproxy12C200Mi--
vmselectvmselect15C3Gi--
vmstorage-clustervmstorage12C6Gi30G7 天内约 16.8G 写入