[pgpool-general: 6283] Re: load balance between hosts with same FQDN

Tatsuo Ishii ishii at sraoss.co.jp
Sun Nov 18 09:11:32 JST 2018


Hi bino,

My guess is,

- Load balancing will work. DNS round robin will assign 10.10.10.1 or
  10.10.10.2 to Pgpool-II but it should work.

- Health checking will not work. After health checking detects a fault
  of standby, it notices the Pgpool-II main process that
  replica.pgcluster.service.bino.inc' is down, then it detach standby
  1, even if remaining standby is healthy.

- Streaming replication delay checking will not work. I will report
  the delay for 10.10.10.1 or 10.10.10.2 depending on the DNS round
  robin. So the result will not consistent.
  
Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp

> Dear Tatsuo.
> 
> My Vault ....
> 
> What if :
> 
> #MASTER
> backend_hostname0 = 'master.pgcluster.service.bino.inc'
> backend_port0 = 5432
> backend_weight0 = 1
> backend_data_directory0 = '/psqldata'
> backend_flag0 = 'ALWAYS_MASTER'
> #REPLICAs
> backend_hostname1 = 'replica.pgcluster.service.bino.inc'
> backend_port1 = 5432
> backend_weight1 = 1
> backend_data_directory1 = '/psqldata'
> 
> Sincerely
> -bino-
> 
> On Sat, Nov 17, 2018 at 3:52 PM Tatsuo Ishii <ishii at sraoss.co.jp> wrote:
> 
>> > lets say Currently I have 3 psql hosts, 2 of them have the same 'fqdn'
>> but
>> > different IP.
>> >
>> > master.pgcluster.service.bino.inc. 0 IN    A    10.10.10.3
>> > replica.pgcluster.service.bino.inc. 0 IN A    10.10.10.1
>> > replica.pgcluster.service.bino.inc. 0 IN A    10.10.10.2
>> >
>> > (note: DNS server is by Consul)
>> >
>> > My pgpool.conf :
>> >
>> > #MASTER
>> > backend_hostname0 = 'master.pgcluster.service.bino.inc'
>> > backend_port0 = 5432
>> > backend_weight0 = 1
>> > backend_data_directory0 = '/psqldata'
>> > backend_flag0 = 'ALWAYS_MASTER'
>> > #REPLICAs
>> > backend_hostname1 = '10.10.10.2'
>> > backend_port1 = 5432
>> > backend_weight1 = 1
>> > backend_data_directory1 = '/psqldata'
>> >
>> > My question is, will the SELECT (read) being loadbalanced between all
>> three
>> > hosts ?
>>
>> I'm not a network expert but I guess 10.10.10.1 will never be used by
>> Pgpool-II, since either 10.10.10.1 or
>> replica.pgcluster.service.bino.inc does not appears in pgpool.conf.
>>
>> Best regards,
>> --
>> Tatsuo Ishii
>> SRA OSS, Inc. Japan
>> English: http://www.sraoss.co.jp/index_en.php
>> Japanese:http://www.sraoss.co.jp
>>


More information about the pgpool-general mailing list