[pgpool-general: 7202] Re: After FailOver.SH Both nodes remain on standby :(

Praveen Kumar K S praveenssit at gmail.com
Tue Aug 18 19:41:44 JST 2020


Below is the status.

ubuntu at pgp1:/etc/pgpool2$ psql -U postgres -h localhost -p 9999 --pset
pager=off -c "show pool_nodes"
 node_id | hostname | port | status | lb_weight |  role   | select_cnt |
load_balance_node | replication_delay | last_status_change
---------+----------+------+--------+-----------+---------+------------+-------------------+-------------------+---------------------
 0       | pg1      | 5432 | down   | 0.500000  | standby | 0          |
false             | 0                 | 2020-08-18 10:36:42
 1       | pg2      | 5432 | up     | 0.500000  | standby | 0          |
true              | 0                 | 2020-08-18 10:36:42
(2 rows)

ubuntu at pgp1:/etc/pgpool2$ psql -U postgres -h pg1 -p 5432 -x -c "select
pg_is_in_recovery();"
Password for user postgres:
-[ RECORD 1 ]-----+--
pg_is_in_recovery | f

ubuntu at pgp1:/etc/pgpool2$ psql -U postgres -h pg2 -p 5432 -x -c "select
pg_is_in_recovery();"
Password for user postgres:
-[ RECORD 1 ]-----+--
pg_is_in_recovery | t


On Tue, Aug 18, 2020 at 3:46 PM Praveen Kumar K S <praveenssit at gmail.com>
wrote:

> Hello,
>
> I'm facing same issue and would like to know
> 1. If failover script fails, how pgpool consider that situation.
> 2. My failover script has failed when failover triggered. Postgres primary
> and slave is working fine. But pgpool continues to show both as standby and
> primary as down. I tried restarting all the services. How can I reset
> pgpool to detect postgres status ?
>
>
> On Mon, Aug 10, 2020 at 1:49 PM Tatsuo Ishii <ishii at sraoss.co.jp> wrote:
>
>> > Thanks for your reply and your time ,
>> >
>> >
>> >
>> > I checked it out , the script in create filename "trigger",    and it
>> is ok  rather than "trigger_file"
>> >
>> > and as you can see recovery.conf  postgress is looking for "trigger"
>> >
>> > as well in the logs  logs  I did  see  message like  "found trigger
>> file moving from hotstandby to master"
>> >
>> >
>> >
>> >
>> >
>> > Here is the recovery.conf file
>> >
>> > root at XXX XXX]# cat recovery.conf
>> >
>> > standby_mode = 'on'
>> >
>> > primary_conninfo = 'host=mgrdb120-hb port=5432 user=XXXX password=XXXX'
>> >
>> > #restore_command = 'scp mgrdb120-hb:/home/postgres/archive/%f %p'
>> >
>> > trigger_file = '/home/postgres/databases/fabrix/trigger'
>> >
>> > archive_cleanup_command = 'ssh mgrdb120-hb
>> /home/postgres/pg_utils/archive_cleanup.sh %r'
>> >
>> > recovery_target_timeline = 'latest'
>> >
>> > [root at mgrdb119 fabrix]#
>> >
>> >
>> >
>> > So now my question is still relevant why pgpool doesn't recognize the
>> postgress as primary
>>
>> Pgpool says:
>> 2020-07-20 09:24:15: pid 4076: LOG:  failover: set new primary node: -1
>> 2020-07-20 09:24:15: pid 4076: LOG:  failover: set new master node: 1
>>
>> When was the PostgreSQL promoted? My wild guess is, the promotion took
>> too long time and pgpool missed it.
>>
>> Best regards,
>> --
>> Tatsuo Ishii
>> SRA OSS, Inc. Japan
>> English: http://www.sraoss.co.jp/index_en.php
>> Japanese:http://www.sraoss.co.jp
>> _______________________________________________
>> pgpool-general mailing list
>> pgpool-general at pgpool.net
>> http://www.pgpool.net/mailman/listinfo/pgpool-general
>>
>
>
> --
>
>
> *Regards,*
>
>
> *K S Praveen KumarM: +91-9986855625 *
>


-- 


*Regards,*


*K S Praveen KumarM: +91-9986855625 *
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20200818/f8a45716/attachment.html>


More information about the pgpool-general mailing list