Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Max. table FREEZE age shows High values for Partitioned tables #760

Open
AnDBAIdewe opened this issue Mar 25, 2024 · 0 comments
Open

Max. table FREEZE age shows High values for Partitioned tables #760

AnDBAIdewe opened this issue Mar 25, 2024 · 0 comments
Assignees

Comments

@AnDBAIdewe
Copy link

Since PG15, the pg_stat_user_tables includes partitioned tables (relkind 'p'). The age(relfrozenxid) of this tables is always 2147483647, which results in a red-flagged "Max. table FREEZE age" in Health check dashboard. It would make sense to exclude partitioned tables from this metric, as it conceales real data metrics. The partitions each act as a normal table (relkind 'r') and are properly monitored.
Same behavior is noticed with PgWatch2 V1.10.0 and PgWatch2-postgres V1.12.0, even after updating metric definitions.

PG14:
select s.relname, relkind, age(relfrozenxid) from pg_class p , pg_stat_user_tables s where p.relname=s.relname and s.relname like 'analytics_cycle_analytics_issue%' order by age(relfrozenxid) desc, s.relname;
relname | relkind | age
-------------------------------------------------+---------+------------
analytics_cycle_analytics_issue_stage_events_00 | r | 321
analytics_cycle_analytics_issue_stage_events_01 | r | 321
analytics_cycle_analytics_issue_stage_events_02 | r | 321

PG15:
select s.relname, relkind, age(relfrozenxid) from pg_class p , pg_stat_user_tables s where p.relname=s.relname and s.relname like 'analytics_cycle_analytics_issue%' order by age(relfrozenxid) desc, s.relname;
relname | relkind | age
-------------------------------------------------+---------+------------
analytics_cycle_analytics_issue_stage_events | p | 2147483647
analytics_cycle_analytics_issue_stage_events_00 | r | 321
analytics_cycle_analytics_issue_stage_events_01 | r | 321
analytics_cycle_analytics_issue_stage_events_02 | r | 321

@pashagolub pashagolub self-assigned this May 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Todo
Development

No branches or pull requests

2 participants