You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jul 6, 2021. It is now read-only.
Copy file name to clipboardExpand all lines: HELP.md
+35-35Lines changed: 35 additions & 35 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,20 +7,20 @@ This group determines the available resources such as hardware characteristics o
7
7
General information about operational systems where the observed Postgres master and its replicas operate.
8
8
9
9
> Insights:
10
-
>
10
+
>
11
11
> - Hardware and software differences (OS versions, Linux kernel versions, CPU, Memory). If the observed master and its replicas run on different platforms, it might cause issues with binary replication.
12
-
>
12
+
>
13
13
> - Memory settings tuning. (Examples: is swap enabled? Are huge pages used?) Observing state of memory about memory consumption by database may lead to recommendations of changes to improve system performance.
14
-
>
14
+
>
15
15
> - Information about virtualization type.
16
16
17
17
18
18
### A002 Postgres Version Information
19
19
20
20
This report answers the following questions:
21
-
- Do all nodes have the same Postgres version?
21
+
- Do all nodes have the same Postgres version?
22
22
- Is the minor version being used up-to-date? Keeping the minor version of the database up-to-date is recommended to decrease chances to encounter with bugs, performance and security issues?
23
-
- Is the major version currently supported by the community?
23
+
- Is the major version currently supported by the community?
24
24
- Will the major version be supported by the community during the next 12 months?
25
25
- If the minor version is not the most recent, are any critical bugfixes released that need to be applied ASAP?
26
26
@@ -40,26 +40,26 @@ The following is included:
40
40
- The uptime. Sometimes low uptime may indicate an unplanned, accidental restart of the database.
41
41
- General information: how many databases are on one instance, what is their size, replication mode, age of statistics.
42
42
- Information about replicas, replication modes, replication delays.
43
-
- Ratio of forced checkpoints among all checkpoints registered since statistics reset time.
44
-
> Insights: Frequent checkpoints in most cases create an excessive load on the disk subsystem. Identifying this fact will allow the more optimal disk utilization.
45
-
- How big is the observed database (the cluster may have multiple databases)?
46
-
> Insight: if the database is smaller than RAM, there are good chances to avoid intensive disk IO in most operations
47
-
- Cache Effectiveness: percentage of buffer pool hits.
48
-
> Insight: if it is not more than 95% on all nodes, it might be a good sign that the buffer pool size needs to be increased.
49
-
- Successful Commits: percentage of successfully committed transactions.
50
-
> Insight: if the value is not more than 99%, it might be a sign of logic issues with application code leading to high rates of ROLLBACK events.
51
-
- Temp Files per day: how many temporary files were generated per day in average, since last statistics reset time.
52
-
> Insight: if this value is high (thousands), it is a signal that work_mem should be increased.
53
-
- Deadlocks per day.
54
-
> Insight: significant (dozens) daily number of deadlocks is a sign of issues with application logic that needs redesign.
43
+
- Ratio of forced checkpoints among all checkpoints registered since statistics reset time.
44
+
> Insights: Frequent checkpoints in most cases create an excessive load on the disk subsystem. Identifying this fact will allow the more optimal disk utilization.
45
+
- How big is the observed database (the cluster may have multiple databases)?
46
+
> Insight: if the database is smaller than RAM, there are good chances to avoid intensive disk IO in most operations
47
+
- Cache Effectiveness: percentage of buffer pool hits.
48
+
> Insight: if it is not more than 95% on all nodes, it might be a good sign that the buffer pool size needs to be increased.
49
+
- Successful Commits: percentage of successfully committed transactions.
50
+
> Insight: if the value is not more than 99%, it might be a sign of logic issues with application code leading to high rates of ROLLBACK events.
51
+
- Temp Files per day: how many temporary files were generated per day in average, since last statistics reset time.
52
+
> Insight: if this value is high (thousands), it is a signal that work_mem should be increased.
53
+
- Deadlocks per day.
54
+
> Insight: significant (dozens) daily number of deadlocks is a sign of issues with application logic that needs redesign.
55
55
56
56
### A005 Extensions
57
57
58
58
Provides a list of all available and installed (in the current observed database) extensions, with versions. Insight: if there is a newer version of an installed extension, the report will highlight it, meaning that update is needed.
59
59
60
60
### A006 Postgres Setting Deviations
61
61
62
-
Helps to check that there are no differences in Postgres configuration on the observed nodes (except `transaction_read_only` and pg_stat_kcache’s `linux_hz`).
62
+
Helps to check that there are no differences in Postgres configuration on the observed nodes (except `transaction_read_only` and pg_stat_kcache’s `linux_hz`).
63
63
64
64
> Insights:
65
65
> - In general, any differences in configuration on master and its replicas might lead to issues in case of failover. An example: the master is tuned, while replicas are not tuned at all or tuned poorly, in the event of failover, a new master cannot operate properly due to poor tuning.
@@ -72,13 +72,13 @@ There are multiple ways to change database settings globally:
72
72
- explicitly, in the configuration file postgresql.conf, and
73
73
- implicitly, using 'ALTER SYSTEM' commands.
74
74
75
-
This report checks if there are settings which were set by implicit (ALTER SYSTEM) way.
75
+
This report checks if there are settings which were set by implicit (ALTER SYSTEM) way.
76
76
77
77
Possible sources of configuration settings (presented in the first column of the report’s table):
78
78
79
79
*`postgresql.auto.conf`: changed via 'ALTER SYSTEM' command.
80
80
*`%any other file pattern%`: changed in additional config included to the main one.
81
-
*`postgresql.conf`: non-default values are set in postgresql.conf.
81
+
*`postgresql.conf`: non-default values are set in postgresql.conf.
82
82
83
83
### A008 Disk Usage and File System Type
84
84
@@ -132,11 +132,11 @@ Shows global and per-table (if any) autovacuum-related Postgres settings.
132
132
133
133
> Insights:
134
134
> - Is any tuning applied (values are not default)?
135
-
> - Are there any custom table autovacuum settings? There are cases when the tables have a custom autovacuum configuration. Tracking such tables will allow you to understand the nature of the functioning of autovacuum workers. Such tables are marked with asterisk (*) in the following reports.
135
+
> - Are there any custom table autovacuum settings? There are cases when the tables have a custom autovacuum configuration. Tracking such tables will allow you to understand the nature of the functioning of autovacuum workers. Such tables are marked with asterisk (\*) in the following reports.
136
136
137
-
### F002 Autovacuum: Transaction Wraparound Check
137
+
### F002 Autovacuum: Transaction ID Wraparound Check
138
138
139
-
Shows a distance in % to transaction wraparound disaster for every database.
139
+
Shows a distance in % to transaction ID wraparound disaster for every database.
140
140
141
141
> Insights:
142
142
> If % is higher than 50%, autovacuum tuning should be considered as soon as possible.
@@ -160,14 +160,14 @@ Estimated table and index bloat is presented in this report.
160
160
> - Objects with a high percentage of bloat lead to wasted disk space, degradation in query performance, additional CPU costs, and excessive read load on the disk.
161
161
> This report is based on estimations. The errors in bloat estimates may be significant (in some cases, up to 15% and event more). Use it only as an indicator of potential issues.
162
162
> - Checks the following things:
163
-
> - Extreme (>90%) level of heap or index bloat estimated.
164
-
> - Significant (>40%) level of heap or index bloat estimated.
163
+
> - Extreme (>90%) level of heap or index bloat estimated.
164
+
> - Significant (>40%) level of heap or index bloat estimated.
165
165
166
166
### F008 Autovacuum: Resource Usage
167
167
168
-
Shows a table with Postgres settings related to autovacuum resource usage.
168
+
Shows a table with Postgres settings related to autovacuum resource usage.
169
169
170
-
> Insights:
170
+
> Insights:
171
171
> - Is `autovacuum_max_workers` not default? (When CPU cores or vCPUs >= 10).
172
172
> - Is `autovacuum_vacuum_cost_limit` / `vacuum_cost_limit` not default?
173
173
> - Isn't `maintenance_work_mem` / `autovacuum_work_mem` too low compared to table sizes and RAM?
@@ -201,7 +201,7 @@ A detailed snapshot report of all connections, grouped by users, databases and s
201
201
Provides information about how "timeout" and locking-related settings are tuned, shows deadlocks counter for every database since statistics reset.
202
202
203
203
> Insights:
204
-
> - Questions worth answering:
204
+
> - Questions worth answering:
205
205
> - Is `statement_timeout` > 0 and <= 30 seconds (good choice for an OLTP system)?
206
206
> - Is `idle_in_transaction_session_timeout` >0 and < 20 minutes (preventing autovacuum and locking issues)?
207
207
> - Is `max_locks_per_transaction` not default (for example, low value may interrupt pg_dump)?
@@ -218,14 +218,14 @@ Shows the list of never used, rarely used and redundant indexes.
218
218
Helps to understand how much space they occupy.
219
219
220
220
> Insights:
221
-
> - Questions worth answering:
221
+
> - Questions worth answering:
222
222
> - Is the total size of unused indexes less than 10% of the DB size (only if statistics is older than 1 week)?
223
223
> - Is statistics saved across restarts?
224
224
> - If statistics age is low, the report should be used with caution.
225
225
226
226
### H003 Non-indexed Foreign Keys
227
227
228
-
Checks if all foreign keys have indexes in referencing tables.
228
+
Checks if all foreign keys have indexes in referencing tables.
229
229
230
230
# K. SQL Query Analysis
231
231
@@ -247,7 +247,7 @@ The grouping is based on the first word of every query.
247
247
248
248
One of the most comprehensive and deep reports. Shows Top query groups
249
249
ordered by total execution time during the observation period (`total_time` in
250
-
pg_stat_statements). Good start for query optimization.
250
+
pg_stat_statements). Good start for query optimization.
251
251
252
252
> Insights:
253
253
> - The first question to answer: Are there any query groups with `total_time` ratio >50% of overall `total_time`? If we have this type of query, it is definitely worth optimizing it.
@@ -262,11 +262,11 @@ face of a growing amount of data.
262
262
263
263
### L001 Table Sizes
264
264
265
-
Displays the size of tables and their components (indexes, TOAST, the table itself).
265
+
Displays the size of tables and their components (indexes, TOAST, the table itself).
266
266
267
-
> - Questions worth answering:
268
-
> - Does the size of indexes for each table not exceed heap (with toast) size?
269
-
> - Are there any non-indexes tables which size is > 10 MiB?
267
+
> - Questions worth answering:
268
+
> - Does the size of indexes for each table not exceed heap (with toast) size?
269
+
> - Are there any non-indexes tables which size is > 10 MiB?
270
270
> - Are there any non-partitioned tables of size > 100 GiB?
271
271
272
272
### L003 Integer (int2, int4) Out-of-range Risks in PKs
0 commit comments