Change XID and mxact limits to warn at 40M and stop at 3M.
authorNoah Misch <noah@leadboat.com>
Sat, 1 Aug 2020 22:31:01 +0000 (15:31 -0700)
committerNoah Misch <noah@leadboat.com>
Sat, 1 Aug 2020 22:31:01 +0000 (15:31 -0700)
commitcd5e82256de5895595cdd99ecb03aea15b346f71
tree747def403ed87cd47308b611a7cb99eccab6db8d
parent9f9682783bea74bf8d93cac4f7dd65fa677f5dc7
Change XID and mxact limits to warn at 40M and stop at 3M.

We have edge-case bugs when assigning values in the last few dozen pages
before the wrap limit.  We may introduce similar bugs in the future.  At
default BLCKSZ, this makes such bugs unreachable outside of single-user
mode.  Also, when VACUUM began to consume mxacts, multiStopLimit did not
change to compensate.

pg_upgrade may fail on a cluster that was already printing "must be
vacuumed" warnings.  Follow the warning's instructions to clear the
warning, then run pg_upgrade again.  One can still, peacefully consume
98% of XIDs or mxacts, so DBAs need not change routine VACUUM settings.

Discussion: https://postgr.es/m/20200621083513.GA3074645@rfd.leadboat.com
doc/src/sgml/maintenance.sgml
src/backend/access/transam/multixact.c
src/backend/access/transam/varsup.c