I just noticed that freezing a tuple (in vacuumlazy.c) is not
WAL-logged. That leads to this scenario:
postgres=# CREATE TABLE foo (bar int);
CREATE TABLE
postgres=# INSERT INTO foo VALUES (1);
INSERT 0 1
postgres=# SELECT xmin,xmax, bar FROM foo;
xmin | xmax | bar
------+------+-----
669 | 0 | 1
(1 row)
postgres=# VACUUM FREEZE foo;
VACUUM
killall -9 postgres + restart
postgres=# SELECT xmin,xmax, bar FROM foo;
xmin | xmax | bar
------+------+-----
669 | 0 | 1
(1 row)
postgres=# SELECT relminxid FROM pg_class WHERE relname='foo';
relminxid
-----------
672
(1 row)
It looks like a bug to me.
--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com
---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?
http://archives.postgresql.org