如何查看Cassandra每秒的读/写次数。

huangapple go评论63阅读模式
英文:

How to view Cassandra number of read/write per seconds

问题

以前,我使用了 k8ssandra-operator 1.4 部署了 Cassandra,并启用了 kube-prometheus-stack,直接通过 CQL 将数据插入到 C* 节点。在 Web UI 上访问 Grafana 仪表板时,我可以看到 k8ssandra:read/write 的速率。

但在启用了 stargate 并将数据插入到 stargate 服务之后,我无法看到这些指标。我假设 Stargate 的工作方式是写入/刷新临时 SSTables,因此不会记录 k8ssandra:read/write 指标。

是否有任何方法可以查看这些指标,例如 nodetoolprometheus

解决方案

我按照 @Arron 的建议添加了以下配置,并且它起作用了,必须重新启动 stargate 和相关的 prometheus pods。

stargate:
  enabled: true
  replicas: 3
  heapMB: 1024
  cpuReqMillicores: 1000
  cpuLimMillicores: 1000
  telemetry:
    prometheus:
      enabled: true

如何查看Cassandra每秒的读/写次数。

英文:

Previously, I deployed Cassandra with k8ssandra-operator 1.4 with kube-prometheus-stack enabled, inserting data directly to C* node via CQL. I can see k8ssandra:read/write rates when access Grafana dashboard on Web UI.

But after enabling stargate, and inserting to stargate service, I can't see those metrics. I assumed the way Stargate work is to write/flush temporary SSTables so k8ssandra:read/write metrics are not logged.

如何查看Cassandra每秒的读/写次数。

Is there any way to see those metrics, nodetool? prometheus?

Solutions

I added these config follow @Arron answer and it worked, have to restart stargate and related prometheus pods.

stargate:
  enabled: true
  replicas: 3
  heapMB: 1024
  cpuReqMillicores: 1000
  cpuLimMillicores: 1000
  telemetry:
    prometheus:
      enabled: true

如何查看Cassandra每秒的读/写次数。

答案1

得分: 1

与K8ssandra团队讨论了这个问题。尝试启用Stargate的Prometheus遥测:

https://docs.k8ssandra.io/reference/crd/releases/k8ssandra-operator-releases/k8ssandra-operator-crds-1.4/#stargatespectelemetryprometheus

Stargate.spec.telemetry.prometheus
↩ 父级

名称      类型      描述
enabled   布尔值    启用此资源(Cassandra或Stargate)的Prometheus serviceMonitors的创建。

这应该允许这些指标通过。

英文:

Talked to the K8ssandra team on this one. Try enabling Prometheus telemetry for Stargate:

https://docs.k8ssandra.io/reference/crd/releases/k8ssandra-operator-releases/k8ssandra-operator-crds-1.4/#stargatespectelemetryprometheus

Stargate.spec.telemetry.prometheus
↩ Parent

Name	Type	Description	   
enabled	boolean	Enable the creation of Prometheus serviceMonitors for this resource (Cassandra or Stargate).

This should allow those metrics to come through.

huangapple
  • 本文由 发表于 2023年6月15日 17:14:14
  • 转载请务必保留本文链接:https://go.coder-hub.com/76480953.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定