【问题标题】:yace doesn't show any data in grafanayace 在 grafana 中不显示任何数据
【发布时间】:2021-09-21 12:43:02
【问题描述】:

我在 Grafana 中有一个仪表板,它显示了 6 个月前来自 yace cloudwatch 导出器的数据,现在它没有显示任何数据,尽管我可以通过端口转发正确地看到 prometheus 的 mertics。你有什么线索吗? (特别适用于 s3 指标)。

Yace 配置如下:

    - type: s3
      regions:
        - eu-central-1
      addCloudwatchTimestamp: false
      period: 172800
      length: 259200
      metrics:
        - name: NumberOfObjects
          statistics:
            - Maximum
          additionalDimensions:
            - name: StorageType
              value: AllStorageTypes
        - name: BucketSizeBytes
          statistics:
            - Sum
          additionalDimensions:
            - name: StorageType
              value: StandardStorage
        - name: BytesUploaded
          statistics:
            - Average
          period: 60
          length: 300
          additionalDimensions:
            - name: FilterId
              value: EntireBucket

yacl pod的部署如下:


apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app.kubernetes.io/name: alt-cloudwatch-exporter
    app.kubernetes.io/version: v0.26.3-alpha
    app.kubernetes.io/part-of: prometheus
  name: alt-cloudwatch-exporter
spec:
  replicas: 1
  selector:
    matchLabels:
      app.kubernetes.io/name: alt-cloudwatch-exporter
  template:
    metadata:
      annotations:
        #iam.amazonaws.com/role: "arn:aws:iam::%%AWS_ACCOUNT_NUMBER%%:role/k8s/pod/id_CloudWatchMetricsExportAccess"
      labels:
        app.kubernetes.io/name: alt-cloudwatch-exporter
        app.kubernetes.io/version: v0.26.3-alpha
        app.kubernetes.io/part-of: prometheus
    spec:
      containers:
        - name: alt-cloudwatch-exporter
          image: quay.io/invisionag/yet-another-cloudwatch-exporter:v0.26.3-alpha
          imagePullPolicy: IfNotPresent
          args:
            - "--config.file=/cfg/yace-config.yaml"
          env:
            - name: gateway
              value: prometheus-pushgateway.monitor-system:9091
          ports:
            - containerPort: 5000
              protocol: TCP
          volumeMounts:
            - name: config-volume
              mountPath: /cfg
      volumes:
        - name: config-volume
          configMap:
            name: alt-cloudwatch-exporter-config

---
apiVersion: v1
kind: Service
metadata:
  labels:
    app.kubernetes.io/name: alt-cloudwatch-exporter
    app.kubernetes.io/version: v0.26.3-alpha
    app.kubernetes.io/part-of: prometheus
  name: alt-cloudwatch-exporter
spec:
  type: ClusterIP
  ports:
    - name: metrics
      protocol: TCP
      targetPort: 5000
      port: 9144
  selector:
    app.kubernetes.io/name: alt-cloudwatch-exporter

---
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  labels:
    app.kubernetes.io/name: alt-cloudwatch-exporter
    app.kubernetes.io/version: v0.26.3-alpha
    app.kubernetes.io/part-of: prometheus
  name: alt-cloudwatch-exporter
spec:
  endpoints:
    - port: metrics
      interval: 60s
  selector:
    matchLabels:
      app.kubernetes.io/name: alt-cloudwatch-exporter

【问题讨论】:

    标签: amazon-s3 devops monitoring grafana amazon-cloudwatch


    【解决方案1】:

    如果您使用 prometheus 运算符,则需要使用中间脚本 pod 处理数据,否则它们将无法消化。 YACE 以 aws_yace 的形式创建指标标签,因此除非您的应用被明确称为 yace,否则您将看不到任何内容

    【讨论】:

      猜你喜欢
      • 2022-08-10
      • 2022-11-01
      • 1970-01-01
      • 1970-01-01
      • 2021-05-23
      • 2021-04-29
      • 2019-10-15
      • 2017-03-14
      • 2020-09-18
      相关资源
      最近更新 更多