pgsql: Write an end-of-backup WAL record at pg_stop_backup(), and wait

Поиск
Список
Период
Сортировка
От heikki@postgresql.org (Heikki Linnakangas)
Тема pgsql: Write an end-of-backup WAL record at pg_stop_backup(), and wait
Дата
Msg-id 20100104125050.1DEB9753FB7@cvs.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Log Message:
-----------
Write an end-of-backup WAL record at pg_stop_backup(), and wait for it at
recovery instead of reading the backup history file. This is more robust,
as it stops you from prematurely starting up an inconsisten cluster if the
backup history file is lost for some reason, or if the base backup was
never finished with pg_stop_backup().

This also paves the way for a simpler streaming replication patch, which
doesn't need to care about backup history files anymore.

The backup history file is still created and archived as before, but it's
not used by the system anymore. It's just for informational purposes now.

Bump PG_CONTROL_VERSION as the location of the backup startpoint is now
written to a new field in pg_control, and catversion because initdb is
required

Original patch by Fujii Masao per Simon's idea, with further fixes by me.

Modified Files:
--------------
    pgsql/src/backend/access/transam:
        xlog.c (r1.356 -> r1.357)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/transam/xlog.c?r1=1.356&r2=1.357)
    pgsql/src/bin/pg_controldata:
        pg_controldata.c (r1.45 -> r1.46)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/bin/pg_controldata/pg_controldata.c?r1=1.45&r2=1.46)
    pgsql/src/bin/pg_resetxlog:
        pg_resetxlog.c (r1.76 -> r1.77)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/bin/pg_resetxlog/pg_resetxlog.c?r1=1.76&r2=1.77)
    pgsql/src/include/catalog:
        catversion.h (r1.565 -> r1.566)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/include/catalog/catversion.h?r1=1.565&r2=1.566)
        pg_control.h (r1.47 -> r1.48)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/include/catalog/pg_control.h?r1=1.47&r2=1.48)

В списке pgsql-committers по дате отправления:

Предыдущее
От: mhasegawa@pgfoundry.org (User Mhasegawa)
Дата:
Сообщение: pgbulkload - pgbulkload: - Support encoding conversion (ENCODING =
Следующее
От: tgl@postgresql.org (Tom Lane)
Дата:
Сообщение: pgsql: Improve PGXS makefile system to allow the module's makefile to