pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Anastasia Lubennikova <lubennikovaav@gmail.com>
To: pgsql-hackers@postgresql.org
Cc: Michael Paquier <michael.paquier@gmail.com>
Cc: David Steele <david@pgmasters.net>
Subject: Re: Backend crash on non-exclusive backup cancel
Date: Tue, 14 Mar 2017 15:27:14 +0000
Message-ID: <20170314152714.22419.22145.pgcf@coridan.postgresql.org> (raw)
In-Reply-To: <CAB7nPqR9xvq_wYKFjUYF1CECFLRbe6xGhGWaCv_yE8pZU71Ztw@mail.gmail.com>
References: <c86627c3-fcdd-9b67-5a03-e2f1113d1b14@pgmasters.net>
	<CAB7nPqR9xvq_wYKFjUYF1CECFLRbe6xGhGWaCv_yE8pZU71Ztw@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

As far as I understand, in this thread were discussed two bugs of pg_stop_backup().
Thanks to the clear descriptions above, I easily reproduced both of them.

BUG#1:
Server crashes on assertion on call of pg_stop_backup(false) after interrupted call of pg_stop_backup(false).
TRAP: FailedAssertion("!(XLogCtl->Insert.nonExclusiveBackups > 0)", File: "xlog.c", Line: 10747)

BUG#2:
Failure to start an exclusive backup with the same name, if previous exclusive backup was stopped in another session.

Both problems seem to be fixed with patch "backup-session-locks-fixes.patch".
Speaking of the patch itself, I have a question: shouldn't we also update sessionBackupState
in pg_stop_backup_callback() along with XLogCtl->Insert.exclusiveBackupState?

And couple of minor notes:
1) + * Routines to starting stop, and get status of a base backup
Probably should be: + * Routines to start, stop and get status of a base backup
And also this comment should be moved below the enum.

2) This is used in parallel of the shared memory status 
s/ in parallel of/ in parallel with


The new status of this patch is: Waiting on Author

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers


view thread (15+ messages)  latest in thread

Message-ID: <20170314152714.22419.22145.pgcf@coridan.postgresql.org>
Permalink:  ../20170314152714.22419.22145.pgcf@coridan.postgresql.org/
Also on:    postgresql.org/message-id/20170314152714.22419.22145.pgcf@coridan.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: lubennikovaav@gmail.com, pgsql-hackers@postgresql.org, michael.paquier@gmail.com, david@pgmasters.net
  Subject: Re: Backend crash on non-exclusive backup cancel
  In-Reply-To: <20170314152714.22419.22145.pgcf@coridan.postgresql.org>
  References: <c86627c3-fcdd-9b67-5a03-e2f1113d1b14@pgmasters.net> <CAB7nPqR9xvq_wYKFjUYF1CECFLRbe6xGhGWaCv_yE8pZU71Ztw@mail.gmail.com> <20170314152714.22419.22145.pgcf@coridan.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox