support of multiple databases on different hosts by pgpool2
0
votes
1
answer
708
views
Let's assume We have 2 databases:
Database1 is located on host1 and host2
Database2 is located on host3 and host4
If I'll use pgpool2 to connect to these 2 databases with single pgpool config for backend configuration:
backend_hostname0 = 'host1'
backend_port0 = 5432
backend_weight0 = 1
backend_hostname1 = 'host2'
backend_port1 = 5433
backend_weight1 = 1
backend_hostname2 = 'host3'
backend_port2 = 5434
backend_weight2 = 1
backend_hostname3 = 'host4'
backend_port3 = 5435
backend_weight3 = 1
With this kind of configuration, will pgpool2 throw an error in case of trying to connect to Database2 for example which is absent on host1 and host2 or it will determine easily necessary hosts which contain appropriate database with error and coordinate client in appropriate way to connect to it?
Why I am asking this, because I don't see that pgpool supports something like conf.d directory where I can put separately hosts with different databases in order to connect to them via clients. Instead I see support only of single config file which is **pgpool.conf** for backend definition.
Asked by user54
(135 rep)
Dec 9, 2020, 08:49 PM
Last activity: Feb 12, 2025, 10:02 PM
Last activity: Feb 12, 2025, 10:02 PM