harbor icon indicating copy to clipboard operation
harbor copied to clipboard

Harbor export cannot expose some indicators!

Open QiuToo opened this issue 2 years ago • 2 comments

When I enable metrics indicators in harbor v2.3.5 and harbor v2.4.4, some indicators cannot be obtained. 无法获取到的指标清单: harbor_project_artifact_total harbor_task_concurrency registry_http_request_duration_seconds harbor_jobservice_task_total harbor_jobservice_task_process_time_seconds

$ curl http://192.168.2.22:9099/metrics | grep harbor_project_artifact_total null $ curl http://192.168.2.22:9099/metrics?comp=registry | grep registry_http_request_duration_seconds null $ curl http://192.168.2.22:9099/metrics?comp=jobservice | grep harbor_jobservice_task_tota null $ curl http://192.168.2.22:9099/metrics?comp=jobservice | grep harbor_jobservice_task_process_time_seconds

$ cat harbor.yml metric: enabled: true port: 9099 path: /metrics $ cat /etc/prometheus/prometheus.yml scrape_configs:

  • job_name: "prometheus" static_configs:
    • targets: ["localhost:9090"]
  • job_name: 'node-exporter' static_configs:
    • targets:
      • '192.168.2.22:9100'
  • job_name: "harbor-exporter" scrape_interval: 20s static_configs:
    • targets: ['192.168.2.22:9099']
  • job_name: 'harbor-core' params: comp: ['core'] static_configs:
    • targets: ['192.168.2.22:9099']
  • job_name: 'harbor-registry' params: comp: ['registry'] static_configs:
    • targets: ['192.168.2.22:9099']
  • job_name: 'harbor-jobservice' params: comp: ['jobservice'] static_configs:
    • targets: ['192.168.2.22:9099']

QiuToo avatar Aug 04 '22 14:08 QiuToo

When the warehouse has not been operated, there will be no such indicators. For example, when there is no mirror in the harbor, the indicator harbor_project_artifact_total does not exist.

lengrongfu avatar Aug 05 '22 06:08 lengrongfu

@QiuToo Do you have images or scheduled jobs in your harbor?

chlins avatar Aug 10 '22 01:08 chlins

@QiuToo你的港口有图像或预定的工作吗? No, but I can't find this indicator in the primetheus UI.

QiuToo avatar Aug 11 '22 14:08 QiuToo

This issue is being marked stale due to a period of inactivity. If this issue is still relevant, please comment or remove the stale label. Otherwise, this issue will close in 30 days.

github-actions[bot] avatar Oct 11 '22 09:10 github-actions[bot]

This issue was closed because it has been stalled for 30 days with no activity. If this issue is still relevant, please re-open a new issue.

github-actions[bot] avatar Nov 11 '22 09:11 github-actions[bot]