pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: pg_rewind: Don't error if the two clusters are already on the sa
5+ messages / 4 participants
[nested] [flat]

* pgsql: pg_rewind: Don't error if the two clusters are already on the sa
@ 2015-12-11 23:33 Peter Eisentraut <peter_e@gmx.net>
  2015-12-12 00:11 ` Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 1 reply; 5+ messages in thread

From: Peter Eisentraut @ 2015-12-11 23:33 UTC (permalink / raw)
  To: pgsql-committers

pg_rewind: Don't error if the two clusters are already on the same timeline

This previously resulted in an error and a nonzero exit status, but
after discussion this should rather be a noop with a zero exit status.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/6b34e5563849edc12896bf5754e8fe7b88012697

Modified Files
--------------
src/bin/pg_rewind/pg_rewind.c            |   59 ++++++++++++++++--------------
src/bin/pg_rewind/t/005_same_timeline.pl |   14 +++++++
2 files changed, 46 insertions(+), 27 deletions(-)


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


^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa
  2015-12-11 23:33 pgsql: pg_rewind: Don't error if the two clusters are already on the sa Peter Eisentraut <peter_e@gmx.net>
@ 2015-12-12 00:11 ` Tom Lane <tgl@sss.pgh.pa.us>
  2015-12-12 01:44   ` Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa Michael Paquier <michael.paquier@gmail.com>
  0 siblings, 1 reply; 5+ messages in thread

From: Tom Lane @ 2015-12-12 00:11 UTC (permalink / raw)
  To: Peter Eisentraut <peter_e@gmx.net>; +Cc: pgsql-committers

Peter Eisentraut <peter_e@gmx.net> writes:
> pg_rewind: Don't error if the two clusters are already on the same timeline
> This previously resulted in an error and a nonzero exit status, but
> after discussion this should rather be a noop with a zero exit status.

Hm, if we're going to do that, shouldn't we back-patch the behavior
change into 9.5 as well?

			regards, tom lane


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



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa
  2015-12-11 23:33 pgsql: pg_rewind: Don't error if the two clusters are already on the sa Peter Eisentraut <peter_e@gmx.net>
  2015-12-12 00:11 ` Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa Tom Lane <tgl@sss.pgh.pa.us>
@ 2015-12-12 01:44   ` Michael Paquier <michael.paquier@gmail.com>
  2015-12-14 15:21     ` Re: [COMMITTERS] pgsql: pg_rewind: Don't error if the two clusters are already on the sa Robert Haas <robertmhaas@gmail.com>
  0 siblings, 1 reply; 5+ messages in thread

From: Michael Paquier @ 2015-12-12 01:44 UTC (permalink / raw)
  To: Tom Lane <tgl@sss.pgh.pa.us>; +Cc: Peter Eisentraut <peter_e@gmx.net>; pgsql-committers

On Sat, Dec 12, 2015 at 9:11 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Peter Eisentraut <peter_e@gmx.net> writes:
>> pg_rewind: Don't error if the two clusters are already on the same timeline
>> This previously resulted in an error and a nonzero exit status, but
>> after discussion this should rather be a noop with a zero exit status.
>
> Hm, if we're going to do that, shouldn't we back-patch the behavior
> change into 9.5 as well?

+1. It would be good to get consistent across branches here.
-- 
Michael


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



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: [COMMITTERS] pgsql: pg_rewind: Don't error if the two clusters are already on the sa
  2015-12-11 23:33 pgsql: pg_rewind: Don't error if the two clusters are already on the sa Peter Eisentraut <peter_e@gmx.net>
  2015-12-12 00:11 ` Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa Tom Lane <tgl@sss.pgh.pa.us>
  2015-12-12 01:44   ` Re: pgsql: pg_rewind: Don't error if the two clusters are already on the sa Michael Paquier <michael.paquier@gmail.com>
@ 2015-12-14 15:21     ` Robert Haas <robertmhaas@gmail.com>
  0 siblings, 0 replies; 5+ messages in thread

From: Robert Haas @ 2015-12-14 15:21 UTC (permalink / raw)
  To: Michael Paquier <michael.paquier@gmail.com>; +Cc: Tom Lane <tgl@sss.pgh.pa.us>; Peter Eisentraut <peter_e@gmx.net>; pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>

On Fri, Dec 11, 2015 at 8:44 PM, Michael Paquier
<michael.paquier@gmail.com> wrote:
> On Sat, Dec 12, 2015 at 9:11 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Peter Eisentraut <peter_e@gmx.net> writes:
>>> pg_rewind: Don't error if the two clusters are already on the same timeline
>>> This previously resulted in an error and a nonzero exit status, but
>>> after discussion this should rather be a noop with a zero exit status.
>>
>> Hm, if we're going to do that, shouldn't we back-patch the behavior
>> change into 9.5 as well?
>
> +1. It would be good to get consistent across branches here.

This is one of the (darned few) things still on the open items list
for 9.5.  Peter, are you going to take care of this?  Or alternatively
make an argument that we shouldn't do this?

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


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



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* pgsql: pg_rewind: Don't error if the two clusters are already on the sa
@ 2015-12-14 23:21 Tom Lane <tgl@sss.pgh.pa.us>
  0 siblings, 0 replies; 5+ messages in thread

From: Tom Lane @ 2015-12-14 23:21 UTC (permalink / raw)
  To: pgsql-committers

pg_rewind: Don't error if the two clusters are already on the same timeline

This previously resulted in an error and a nonzero exit status, but
after discussion this should rather be a noop with a zero exit status.

This is a back-patch of commit 6b34e5563849edc12896bf5754e8fe7b88012697,
plus two changes from commit e50cda78404d6400b1326a996a4fabb144871151
that teach pg_rewind to allow the initial control file states to be
DB_SHUTDOWNED_IN_RECOVERY as well as DB_SHUTDOWNED.  That's necessary
to get the additional regression test case to pass, and the old behavior
seems like rather a foot-gun anyway.

Peter Eisentraut and Tom Lane

Branch
------
REL9_5_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/4b021aa6103f49bece51d58fd5e307d4d03380bc

Modified Files
--------------
src/bin/pg_rewind/pg_rewind.c            |   68 +++++++++++++++++-------------
src/bin/pg_rewind/t/005_same_timeline.pl |   14 ++++++
2 files changed, 52 insertions(+), 30 deletions(-)


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


^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2015-12-14 23:21 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-12-11 23:33 pgsql: pg_rewind: Don't error if the two clusters are already on the sa Peter Eisentraut <peter_e@gmx.net>
2015-12-12 00:11 ` Tom Lane <tgl@sss.pgh.pa.us>
2015-12-12 01:44   ` Michael Paquier <michael.paquier@gmail.com>
2015-12-14 15:21     ` Robert Haas <robertmhaas@gmail.com>
2015-12-14 23:21 pgsql: pg_rewind: Don't error if the two clusters are already on the sa Tom Lane <tgl@sss.pgh.pa.us>

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