View Revisions: Issue #513

Summary 0000513: pgpool showing primary node down even if it is UP.
Revision 2019-05-21 11:01 by administrator
Description Hi i am running pgpool in streaming replication mode with load balancing (master_slave_mode = on, master_slave_sub_mode = 'stream')
with one primary and one replica node

Stop the primary node
 node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | last_status_change
---------+-----------------------------------------------+------+--------+-----------+---------+------------+-------------------+-------------------+---------------------
 0 | statefulset-primary.default.svc.cluster.local | 5432 | down | 0.500000 | primary | 0 | false | 0 | 2019-05-19 17:16:31
 1 | statefulset-replica.default.svc.cluster.local | 5432 | up | 0.500000 | standby | 0 | true | 0 | 2019-05-19 17:16:18



After starting the primary node , still i am getting same output

 node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | last_status_change
---------+-----------------------------------------------+------+--------+-----------+---------+------------+-------------------+-------------------+---------------------
 0 | statefulset-primary.default.svc.cluster.local | 5432 | down | 0.500000 | primary | 0 | false | 0 | 2019-05-19 17:16:31
 1 | statefulset-replica.default.svc.cluster.local | 5432 | up | 0.500000 | standby | 0 | true | 0 | 2019-05-19 17:16:18




2019-05-19 17:18:03: pid 418: DEBUG: do_query: extended:0 query:"SELECT pg_is_in_recovery()"
2019-05-19 17:18:03: pid 418: DEBUG: pool_write: to backend: 1 kind:Q
2019-05-19 17:18:03: pid 418: DEBUG: pool_flush_it: flush size: 32
2019-05-19 17:18:03: pid 418: DEBUG: pool_read: read 75 bytes from backend 1
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'T'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received ROW DESCRIPTION ('T')
2019-05-19 17:18:03: pid 418: DEBUG: do_query: row description: num_fileds: 1
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'D'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received DATA ROW ('D')
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'C'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received COMMAND COMPLETE ('C')
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'Z'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received READY FOR QUERY ('Z')
2019-05-19 17:18:03: pid 418: DEBUG: verify_backend_node_status: there's no primary node
2019-05-19 17:18:03: pid 418: DEBUG: node status[0]: 0
2019-05-19 17:18:03: pid 418: DEBUG: node status[1]: 2




Revision 2019-05-20 02:24 by van
Description Hi i am running pgpool in streaming replication mode with load balancing (master_slave_mode = on, master_slave_sub_mode = 'stream')
with one primary and one replica node

Stop the primary node
 node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | last_status_change
---------+-----------------------------------------------+------+--------+-----------+---------+------------+-------------------+-------------------+---------------------
 0 | statefulset-primary.default.svc.cluster.local | 5432 | down | 0.500000 | primary | 0 | false | 0 | 2019-05-19 17:16:31
 1 | statefulset-replica.default.svc.cluster.local | 5432 | up | 0.500000 | standby | 0 | true | 0 | 2019-05-19 17:16:18



After starting the primary node , still i am getting same output

 node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | last_status_change
---------+-----------------------------------------------+------+--------+-----------+---------+------------+-------------------+-------------------+---------------------
 0 | statefulset-primary.default.svc.cluster.local | 5432 | down | 0.500000 | primary | 0 | false | 0 | 2019-05-19 17:16:31
 1 | statefulset-replica.default.svc.cluster.local | 5432 | up | 0.500000 | standby | 0 | true | 0 | 2019-05-19 17:16:18




2019-05-19 17:18:03: pid 418: DEBUG: do_query: extended:0 query:"SELECT pg_is_in_recovery()"
2019-05-19 17:18:03: pid 418: DEBUG: pool_write: to backend: 1 kind:Q
2019-05-19 17:18:03: pid 418: DEBUG: pool_flush_it: flush size: 32
2019-05-19 17:18:03: pid 418: DEBUG: pool_read: read 75 bytes from backend 1
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'T'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received ROW DESCRIPTION ('T')
2019-05-19 17:18:03: pid 418: DEBUG: do_query: row description: num_fileds: 1
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'D'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received DATA ROW ('D')
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'C'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received COMMAND COMPLETE ('C')
2019-05-19 17:18:03: pid 418: DEBUG: do_query: kind: 'Z'
2019-05-19 17:18:03: pid 418: DEBUG: do_query: received READY FOR QUERY ('Z')
2019-05-19 17:18:03: pid 418: DEBUG: verify_backend_node_status: there's no primary node
2019-05-19 17:18:03: pid 418: DEBUG: node status[0]: 0
2019-05-19 17:18:03: pid 418: DEBUG: node status[1]: 2