hi

2016-08-09 15:39 GMT+03:00 Martín Marqués <mar...@2ndquadrant.com>:

> Hi,
>
> El 08/08/16 a las 05:57, Pekka Rinne escribió:
> >
> > Meanwhile I did some more testing with my environment using repmgr3 and
> > noticed an issue with promoting standby node. Here is roughly what I did.
> >
> > 1. Install repmgr3.1.2 RPM to all nodes as upgrade to previous 2.0.2.
> > 2. I took repmgr release upgrade SQL-scripts from github 3.1 stable and
> > ran those on master (all three scripts in order).
> > 3. on master I stopped postgresql service
> > 4. on standby I said standby promote which does some things and then
> > hangs forever.
> >
> > This standby promote was working fine before repmgr upgrade.
> >
> > There is a COMMIT command visible with ps:
> >
> > 3324 ?        Ss     0:00 postgres: repmgr repmgr <new master IP>(43666)
> > COMMIT waiting for 2/4E000548
>
> You mean it doesn't release the execution and give back the prompt?
>
> Do you by chance have synchronous replication set? That ps output alone
> doesn't say much, but being stuck on COMMIT normally points to failure
> to sync the replication on a standby.
>
>
Yeah, I learned that repmgr3 actually writes to DB during promote. Repmgr2
does not do that. And if the failed master itself is on the synchronized
replicas list then the promote command hangs in commit as its not possible
to sync to that failed node. Solution seemed to be to temporarily comment
out synchronized replicas from postgresql.conf in new master and reload
configfile. Then the promote command returns in command line.

br,
Pekka

Reply via email to