Add pg_wait_sampling metric for vms.

This commit is contained in:
Arseny Sher
2023-11-16 22:04:29 +01:00
parent 779badb7c5
commit f552aa05fa
+15 -9
View File
@@ -48,19 +48,25 @@ files:
}
- filename: postgres_exporter_queries.yml
content: |
postgres_exporter_pg_database_size:
query: "SELECT pg_database.datname, pg_database_size(pg_database.datname) as bytes, 42 as fourtytwo FROM pg_database"
pg_wait_sampling:
query: "select pid, event_type, event, queryid, count from pg_wait_sampling_profile"
cache_seconds: 30
metrics:
- datname:
- pid:
usage: "LABEL"
description: "Name of the database"
- bytes:
description: "backend pid"
- event_type:
usage: "LABEL"
description: "event type"
- event:
usage: "LABEL"
description: "event"
- queryid:
usage: "LABEL"
description: "queryid"
- count:
usage: "GAUGE"
description: "Disk space used by the database"
- fourtytwo:
usage: "GAUGE"
description: "fourtytwo"
description: "count"
build: |
# Build cgroup-tools
#