[pgpool-general: 6457] Load balancing and unused status
Fernando Luizão
fernandoluizao at gmail.com
Fri Mar 15 03:31:47 JST 2019
Hi,
I'm new to pgpool, and I'm trying to use the load balancer.
I have a primary and a hot standby, using native streaming replication.
Versions:
postgresql - 11.2
pgpool - 4.0.2
Here's what I changed in pgpool.conf:
listen_addresses = '*'
port = 5432
backend_hostname0 = '192.168.51.186'
backend_port0 = 5433
backend_weight0 = 0.4
backend_data_directory0 = '/var/lib/postgresql/11/main'
backend_flag0 = 'ALWAYS_MASTER'
backend_hostname1 = '192.168.51.185'
backend_port1 = 5433
backend_weight1 = 0.6
backend_data_directory1 = '/var/lib/postgresql/11/main'
load_balance_mode = on
master_slave_mode = on
master_slave_sub_mode = 'stream'
However, when I inspect the nodes on pgpool, I get the following:
postgres=# show pool_nodes;
node_id | hostname | port | status | lb_weight | role |
select_cnt | load_balance_node | replication_delay | last_status_change
---------+----------------+------+--------+-----------+---------+------------+-------------------+-------------------+---------------------
0 | 192.168.51.186 | 5433 | up | 0.400000 | primary | 6113
| true | 0 | 2019-03-14 11:39:15
1 | 192.168.51.185 | 5433 | unused | 0.600000 | standby | 0
| false | 0 | 2019-03-14 11:39:15
All queries are being redirected to primary. I can query the standby
directly, so everything seems fine with my replication setup.
Why it says the standby is unused? I'm missing something in the
configuration?
Thanks,
Fernando
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.pgpool.net/pipermail/pgpool-general/attachments/20190314/cf044d1f/attachment.htm>
More information about the pgpool-general
mailing list