I'm currently facing with a strange behavior during HotStandby Testing.
That's what i'm actually doing:
MASTER:
CREATE DATABASE foo;
<do something in there, e.g. restoring a dump>
<wait until xlog segments get consumed by standby node (using
archive_timeout)>
STANDBY:
postgres=# SELECT oid, datname FROM pg_database;
oid | datname
-------+-----------
1 | template1
11561 | template0
11562 | postgres
16384 | test
16390 | test2
17872 | bernd
17873 | foo
$ psql foo
DEBUG: forked new backend, pid=19967 socket=7
FATAL: database "foo" does not exist
$ cat standby/global/pg_database
"template1" 1 1663 666
"template0" 11561 1663 666
"postgres" 11562 1663 666
"test" 16384 1663 666
"test2" 16390 1663 666
"bernd" 17872 1663 666
Obviously, the pg_database file wasn't updated. I've traced through the
recovery process a little bit and i see BuildFlatFile() called during
xact_redo_commit(), however, write_database_file() doesn't write out the
new database records. Funny thing: the same happened to the database
"bernd" before, so it seems to me the new database record is not visible to
write_database_file() during redo?
--
Thanks
Bernd
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers