aboutsummaryrefslogtreecommitdiff
path: root/src/backend/tcop/postgres.c
diff options
context:
space:
mode:
authorFujii Masao <fujii@postgresql.org>2017-01-17 17:30:26 +0900
committerFujii Masao <fujii@postgresql.org>2017-01-17 17:30:26 +0900
commitdfe348c1b1ca5327cf2ff058b795ac188d442715 (patch)
tree831f90e157d74d6ea8b0a9c1cb96a4c412bd8b0b /src/backend/tcop/postgres.c
parenta23ea8f65e07aa56a501bbdd68068b52469d77cf (diff)
downloadpostgresql-dfe348c1b1ca5327cf2ff058b795ac188d442715.tar.gz
postgresql-dfe348c1b1ca5327cf2ff058b795ac188d442715.zip
Fix an assertion failure related to an exclusive backup.
Previously multiple sessions could execute pg_start_backup() and pg_stop_backup() to start and stop an exclusive backup at the same time. This could trigger the assertion failure of "FailedAssertion("!(XLogCtl->Insert.exclusiveBackup)". This happend because, even while pg_start_backup() was starting an exclusive backup, other session could run pg_stop_backup() concurrently and mark the backup as not-in-progress unconditionally. This patch introduces ExclusiveBackupState indicating the state of an exclusive backup. This state is used to ensure that there is only one session running pg_start_backup() or pg_stop_backup() at the same time, to avoid the assertion failure. Back-patch to all supported versions. Author: Michael Paquier Reviewed-By: Kyotaro Horiguchi and me Reported-By: Andreas Seltenreich Discussion: <87mvktojme.fsf@credativ.de>
Diffstat (limited to 'src/backend/tcop/postgres.c')
0 files changed, 0 insertions, 0 deletions