The vacuum freeze failed to reduce the age of table
search cancel

The vacuum freeze failed to reduce the age of table

book

Article ID: 296714

calendar_today

Updated On:

Products

VMware Tanzu Greenplum

Issue/Introduction

In some scenarios, we may observe that the "vacuum freeze" command failed to reduce the age of the table. for example:
gpadmin=# select relname, relfrozenxid,  age(relfrozenxid)  from pg_class where oid = 'vacuum_test_heap_table'::regclass::oid;
        relname         | relfrozenxid | age
------------------------+--------------+-----
 vacuum_test_heap_table |         1955 | 101
(1 row)

gpadmin=# vacuum FREEZE vacuum_test_heap_table;
VACUUM
gpadmin=# select relname, relfrozenxid,  age(relfrozenxid)  from pg_class where oid = 'vacuum_test_heap_table'::regclass::oid;
        relname         | relfrozenxid | age
------------------------+--------------+-----
 vacuum_test_heap_table |         1955 | 102
(1 row)
But if we do the same "vacuum freeze" command again, the age will be reduced:
gpadmin=# vacuum FREEZE vacuum_test_heap_table;
VACUUM
gpadmin=# select relname, relfrozenxid,  age(relfrozenxid)  from pg_class where oid = 'vacuum_test_heap_table'::regclass::oid;
        relname         | relfrozenxid | age
------------------------+--------------+-----
 vacuum_test_heap_table |         2057 |   1
(1 row) 


Environment

Product Version: 6.16

Resolution

The R&D team has found this issue via Jira ticket: MPP-31597
The issue will be fixed under 6.18.0 and afterward