From: | ITAGAKI Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Operation needed for datfrozenxid bug? |
Date: | 2008-09-29 02:31:26 |
Message-ID: | 20080929111542.8E96.52131E4D@oss.ntt.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hello,
The datfrozenxid bug is fixed in 8.3.4,
but do I need additional operations after upgrade postgres binaries?
| Fix potential miscalculation of datfrozenxid (Alvaro)
| This error may explain some recent reports of failure
| to remove old pg_clog data.
I assume that pg_database.datfrozenxid is wrongly set to 3
(FirstNormalTransactionId) if the bug has occurred.
1. Can I use the following SQL to check whether the bug has occurred?
SELECT * FROM pg_database WHERE datfrozenxid = 3
(will return some rows under the bug.)
2. What is needed to fix the corrupted system catalog,
something like the following SQL?
UPDATE pg_database SET datfrozenxid = relfrozenxid
FROM (SELECT relfrozenxid FROM pg_class
WHERE relkind IN ('r', 't')
ORDER BY age(relfrozenxid) DESC LIMIT 1) AS tmp
WHERE datname = current_database();
Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Dunstan | 2008-09-29 02:58:24 | Re: parallel pg_restore - WIP patch |
Previous Message | pgsql | 2008-09-29 01:27:52 | Re: Ad-hoc table type? |