Harbor
This integration is enabled by default.
Versions supported: > v2.3
This integration is out-of-the-box, so it doesn’t require any exporter.
This integration has 45 metrics.
Timeseries generated: 800 timeseries
List of Alerts
Alert | Description | Format |
---|---|---|
[Harbor] Harbor Core Is Down | Harbor Core Is Down | Prometheus |
[Harbor] Harbor Database Is Down | Harbor Database Is Down | Prometheus |
[Harbor] Harbor Registry Is Down | Harbor Registry Is Down | Prometheus |
[Harbor] Harbor Redis Is Down | Harbor Redis Is Down | Prometheus |
[Harbor] Harbor Trivy Is Down | Harbor Trivy Is Down | Prometheus |
[Harbor] Harbor JobService Is Down | Harbor JobService Is Down | Prometheus |
[Harbor] Project Quota Is Raising The Limit | Project Quota Is Raising The Limit | Prometheus |
[Harbor] Harbor p99 latency is higher than 10 seconds | Harbor p99 latency is higher than 10 seconds | Prometheus |
[Harbor] Harbor Error Rate is High | Harbor Error Rate is High | Prometheus |
List of Dashboards
Harbor
The dashboard provides information on the Harbour instance status, storage usage, projects and tasks.
List of Metrics
Metric name |
---|
go_build_info |
go_gc_duration_seconds |
go_gc_duration_seconds_count |
go_gc_duration_seconds_sum |
go_goroutines |
go_info |
go_memstats_buck_hash_sys_bytes |
go_memstats_gc_sys_bytes |
go_memstats_heap_alloc_bytes |
go_memstats_heap_idle_bytes |
go_memstats_heap_inuse_bytes |
go_memstats_heap_released_bytes |
go_memstats_heap_sys_bytes |
go_memstats_lookups_total |
go_memstats_mallocs_total |
go_memstats_mcache_inuse_bytes |
go_memstats_mcache_sys_bytes |
go_memstats_mspan_inuse_bytes |
go_memstats_mspan_sys_bytes |
go_memstats_next_gc_bytes |
go_memstats_stack_inuse_bytes |
go_memstats_stack_sys_bytes |
go_memstats_sys_bytes |
go_threads |
harbor_artifact_pulled |
harbor_core_http_request_duration_seconds |
harbor_jobservice_task_process_time_seconds |
harbor_project_member_total |
harbor_project_quota_byte |
harbor_project_quota_usage_byte |
harbor_project_repo_total |
harbor_project_total |
harbor_quotas_size_bytes |
harbor_task_concurrency |
harbor_task_queue_latency |
harbor_task_queue_size |
harbor_up |
process_cpu_seconds_total |
process_max_fds |
process_open_fds |
registry_http_request_duration_seconds_bucket |
registry_http_request_size_bytes_bucket |
registry_http_requests_total |
registry_http_response_size_bytes_bucket |
registry_storage_action_seconds_bucket |
Prerequisites
Enable Prometheus Metrics
As seen in the Harbor documentation page Configure the Harbor YML File, to make Harbor expose an endpoint for scraping metrics, you need to set the ‘metric.enabled’ configuration to ’true’.
If you install Harbor with Helm, you need to use the following flag:
--set 'metrics.enabled=true'
Installation
Installing an exporter is not required for this integration.
Agent Configuration
The default agent jobs for this integration are as follows:
- job_name: harbor-exporter-default
kubernetes_sd_configs:
- role: pod
relabel_configs:
- action: keep
source_labels: [__meta_kubernetes_pod_host_ip]
regex: __HOSTIPS__
- action: drop
source_labels: [__meta_kubernetes_pod_annotation_promcat_sysdig_com_omit]
regex: true
- source_labels: [__meta_kubernetes_pod_phase]
action: keep
regex: Running
- action: keep
source_labels:
- __meta_kubernetes_pod_container_name
- __meta_kubernetes_pod_container_port_number
regex: exporter;8080
- action: replace
source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scheme]
target_label: __scheme__
regex: (https?)
- action: replace
source_labels: [__address__,__meta_kubernetes_pod_container_port_number]
regex: ([^:]+)(?::\d+)?;(\d+)
replacement: $1:8001
target_label: __address__
- action: replace
source_labels: [__meta_kubernetes_pod_uid]
target_label: sysdig_k8s_pod_uid
- action: replace
source_labels: [__meta_kubernetes_pod_container_name]
target_label: sysdig_k8s_pod_container_name
- job_name: harbor-core-default
kubernetes_sd_configs:
- role: pod
relabel_configs:
- action: keep
source_labels: [__meta_kubernetes_pod_host_ip]
regex: __HOSTIPS__
- action: drop
source_labels: [__meta_kubernetes_pod_annotation_promcat_sysdig_com_omit]
regex: true
- source_labels: [__meta_kubernetes_pod_phase]
action: keep
regex: Running
- action: keep
source_labels:
- __meta_kubernetes_pod_container_name
- __meta_kubernetes_pod_container_port_number
regex: core;8080
- action: replace
source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scheme]
target_label: __scheme__
regex: (https?)
- action: replace
source_labels: [__address__,__meta_kubernetes_pod_container_port_number]
regex: ([^:]+)(?::\d+)?;(\d+)
replacement: $1:8001
target_label: __address__
- action: replace
source_labels: [__meta_kubernetes_pod_uid]
target_label: sysdig_k8s_pod_uid
- action: replace
source_labels: [__meta_kubernetes_pod_container_name]
target_label: sysdig_k8s_pod_container_name
- job_name: harbor-registry-default
kubernetes_sd_configs:
- role: pod
relabel_configs:
- action: keep
source_labels: [__meta_kubernetes_pod_host_ip]
regex: __HOSTIPS__
- action: drop
source_labels: [__meta_kubernetes_pod_annotation_promcat_sysdig_com_omit]
regex: true
- source_labels: [__meta_kubernetes_pod_phase]
action: keep
regex: Running
- action: keep
source_labels:
- __meta_kubernetes_pod_container_name
- __meta_kubernetes_pod_container_port_number
regex: registry;5000
- action: replace
source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scheme]
target_label: __scheme__
regex: (https?)
- action: replace
source_labels: [__address__,__meta_kubernetes_pod_container_port_number]
regex: ([^:]+)(?::\d+)?;(\d+)
replacement: $1:8001
target_label: __address__
- action: replace
source_labels: [__meta_kubernetes_pod_uid]
target_label: sysdig_k8s_pod_uid
- action: replace
source_labels: [__meta_kubernetes_pod_container_name]
target_label: sysdig_k8s_pod_container_name
- job_name: harbor-jobservice-default
kubernetes_sd_configs:
- role: pod
relabel_configs:
- action: keep
source_labels: [__meta_kubernetes_pod_host_ip]
regex: __HOSTIPS__
- action: drop
source_labels: [__meta_kubernetes_pod_annotation_promcat_sysdig_com_omit]
regex: true
- source_labels: [__meta_kubernetes_pod_phase]
action: keep
regex: Running
- action: keep
source_labels:
- __meta_kubernetes_pod_container_name
- __meta_kubernetes_pod_container_port_number
regex: jobservice;8080
- action: replace
source_labels: [__meta_kubernetes_pod_annotation_prometheus_io_scheme]
target_label: __scheme__
regex: (https?)
- action: replace
source_labels: [__address__,__meta_kubernetes_pod_container_port_number]
regex: ([^:]+)(?::\d+)?;(\d+)
replacement: $1:8001
target_label: __address__
- action: replace
source_labels: [__meta_kubernetes_pod_uid]
target_label: sysdig_k8s_pod_uid
- action: replace
source_labels: [__meta_kubernetes_pod_container_name]
target_label: sysdig_k8s_pod_container_name
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.