Re: pg_rewind exiting with error code 1 when source and target are on the same timeline
От | Michael Paquier |
---|---|
Тема | Re: pg_rewind exiting with error code 1 when source and target are on the same timeline |
Дата | |
Msg-id | CAB7nPqRjZiOGeazc-KzKixscKz=L7fN_Z6m6PxDLJFBxF1A7Pw@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: pg_rewind exiting with error code 1 when source and target are on the same timeline (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: pg_rewind exiting with error code 1 when source and target are on the same timeline
|
Список | pgsql-bugs |
On Tue, Dec 15, 2015 at 8:11 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote: > /* > @@ -385,75 +392,149 @@ sanityChecks(void) > * server is shut down. There isn't any very strong reason for this > * limitation, but better safe than sorry. > */ > - if (datadir_source && ControlFile_source.state != DB_SHUTDOWNED) > + if (datadir_source && > + ControlFile_source.state != DB_SHUTDOWNED && > + ControlFile_source.state != DB_SHUTDOWNED_IN_RECOVERY) > pg_fatal("source data directory must be shut down cleanly\n"); > } > > (Actually, it's only the second of these that is critical to make the > test pass, but I should think we should apply both of them if either.) Yep. > If I apply these, without any of the rest of e50cda78, everything seems > fine. I'm going to go ahead and push that in the interests of getting > some buildfarm cycles on it; but if someone could confirm that this > is not an insane thing to do, it'd help. That's not an insane behavior to me. Actually the patch you pushed to REL9_5_STABLE is missing something: a call to RewindTest::clean_rewind_test(); in t/005 to clean up the nodes involved in the test. I think that in the current state the nodes would stay online until they notice that postmaster.pid is missing. (FWIW there was a patch I sent upthread that did exactly the same thing :) ) -- Michael
В списке pgsql-bugs по дате отправления: