-
Notifications
You must be signed in to change notification settings - Fork 103
Expand file tree
/
Copy pathqueries_general.yml
More file actions
69 lines (64 loc) · 2.82 KB
/
Copy pathqueries_general.yml
File metadata and controls
69 lines (64 loc) · 2.82 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
###
#
# Begin File: PG16 queries_general.yml
#
# Copyright © 2017-2025 Crunchy Data Solutions, Inc. All Rights Reserved.
# Copyright © 2025-2026 Snowflake, Inc. All Rights Reserved.
#
###
ccp_stat_bgwriter:
query: "SELECT checkpoints_timed, checkpoints_req, checkpoint_write_time, checkpoint_sync_time, buffers_checkpoint, buffers_clean, maxwritten_clean, buffers_backend, buffers_backend_fsync, buffers_alloc, stats_reset FROM pg_catalog.pg_stat_bgwriter"
metrics:
- checkpoints_timed:
usage: "GAUGE"
description: "Number of scheduled checkpoints that have been performed"
- checkpoints_req:
usage: "GAUGE"
description: "Number of requested checkpoints that have been performed"
- checkpoint_write_time:
usage: "GAUGE"
description: "Total amount of time that has been spent in the portion of checkpoint processing where files are written to disk, in milliseconds"
- checkpoint_sync_time:
usage: "GAUGE"
description: "Total amount of time that has been spent in the portion of checkpoint processing where files are synchronized to disk, in milliseconds"
- buffers_checkpoint:
usage: "GAUGE"
description: "Number of buffers written during checkpoints"
- buffers_clean:
usage: "GAUGE"
description: "Number of buffers written by the background writer"
- maxwritten_clean:
usage: "GAUGE"
description: "Number of times the background writer stopped a cleaning scan because it had written too many buffers"
- buffers_backend:
usage: "GAUGE"
description: "Number of buffers written directly by a backend"
- buffers_backend_fsync:
usage: "GAUGE"
description: "Number of times a backend had to execute its own fsync call (normally the background writer handles those even when the backend does its own write)"
- buffers_alloc:
usage: "GAUGE"
description: "Number of buffers allocated"
- stats_reset:
usage: "GAUGE"
description: "Time at which these statistics were last reset"
ccp_data_checksum_failure:
query: "SELECT datname AS dbname
, checksum_failures AS count
, coalesce(extract(epoch from (clock_timestamp() - checksum_last_failure)), 0) AS time_since_last_failure_seconds
FROM pg_catalog.pg_stat_database;"
metrics:
- dbname:
usage: "LABEL"
description: "Database name"
- count:
usage: "GAUGE"
description: "Total number of checksum failures on this database"
- time_since_last_failure_seconds:
usage: "GAUGE"
description: "Time interval in seconds since the last checksum failure was encountered"
###
#
# End File: PG16 queries_general.yml
#
###