postgres=# show pool_nodes;-[ RECORD1]---+---node_id|0hostname|192.168.1.108port|5432status |downpg_status|up lb_weight|0.333333role|standby pg_role|primary select_cnt|0load_balance_node|falsereplication_delay|0replication_state|replication_sync_state|last_status_change|2022-12-2000:36:49-...
LOAD_BALANCE_STATUS load_balance_status[MAX_NUM_BACKENDS]; /* to remember which DB node is selected for load balancing */ /* followings till syslog, does not exist in the configuration file */ int num_reset_queries; /* number of queries in reset_query_list */ int num_white_function_li...
postgres=> show pool_nodes; node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | replication_state | replication_syn c_state | last_status_change ---+---+---+---+---+---+---+---+---+---+--- ---+---...
$ psql -p 11000 -c "show pool_nodes" test node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | last_status_change ---+---+---+---+---+---+---+---+---+--- 0 | /tmp | 11002 | up | 0.500000 | primary |...
成功执行完pcp_recovery_node后,检查从节点是否正确加入集群: psql -h192.168.0.5 -p9999-U pgpool postgres -c"show pool_nodes"Password for user pgpool node_id | hostname | port | status | pg_status | lb_weight | role | pg_role | select_cnt | load_balance_node | replication_delay | rep...
pgpool 配置的时候出现两个standby的情况处理办法。 pg10@pghost4->psql -h 10.10.10.15 -p 9999 postgres pg10 Password for user pg10: psql (10.0) Type “help” for help. postgres=# show pool_nodes; node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_...
node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay ---+---+---+---+---+---+---+---+--- 0 | master | 5432 | up | 0.500000 | primary | 0 | false | 0 1 | slave | 5432 | up | 0.500000 | standby | 0 |...
node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay | last_status_change ---+---+---+---+---+---+---+---+---+--- 0 | host0 | 5432 | up | 0.500000 | primary | 2 | false | 0 | 2020-08-27 14:43:54 1...
node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay ---+---+---+---+---+---+---+---+--- 0 | pghost4 | 1921 | down | -nan | standby | 0 | false | 0 1 | pghost5 | 1921 | up | -nan | ...
6. 此时node_id | hostname | port | status | lb_weight | role | select_cnt | load_balance_node | replication_delay ---+---+---+---+---+---+---+---+--- 0 | master | 5432 | up | 0.500000 | standby | 0 | false | 0 1 | slave | 5432 | up | 0.500000 | primary ...