[pgpool-general: 4404] Re: pgpool only write on backend 0

webgourou webgourou2000 at gmail.com
Fri Feb 5 23:50:31 JST 2016


On 05/02/2016 15:46, Tatsuo Ishii wrote:
>> On 05/02/2016 15:25, Tatsuo Ishii wrote:
>>>> On 05/02/2016 15:03, Tatsuo Ishii wrote:
>>>>>> hi,
>>>>>>
>>>>>> I just notice that with replication on and load_balance on
>>>>>> pgpool only on the backend0.
>>>>>>
>>>>>> Exemple:
>>>>>> # 1
>>>>>> backend0 = serv1
>>>>>> backend1 = serv2
>>>>>> #write on serv1
>>>>>>
>>>>>> # if switch
>>>>>> backend0 = serv2
>>>>>> backend1  = serv1
>>>>>> #write on serv2
>>>>>>
>>>>>> Any idea ?
>>>>> Actual query and pgpool-II version, please.
>>>>>
>>>>> Best regards,
>>>>> --
>>>>> Tatsuo Ishii
>>>>> SRA OSS, Inc. Japan
>>>>> English: http://www.sraoss.co.jp/index_en.php
>>>>> Japanese:http://www.sraoss.co.jp
>>>> Hello,
>>>>
>>>> query "CREATE DATABASE toto"; user postgres
>>>> pgpool version 3.4.4 just change because it is the latest stable.
>>> Works for me.
>>>
>>> Can you set:
>>>
>>> log_per_node_statement = on
>>>
>>> in pgpool.conf, execute CREATE DATABASE and send the pgpool log?
>>>
>>> Best regards,
>>> --
>>> Tatsuo Ishii
>>> SRA OSS, Inc. Japan
>>> English: http://www.sraoss.co.jp/index_en.php
>>> Japanese:http://www.sraoss.co.jp
>> I was just doing it ;)
>>
>> 2016-02-05 15:31:11: pid 12344: LOG:  statement: CREATE database essai;
>> 2016-02-05 15:31:11: pid 12344: LOG:  DB node id: 1 backend pid: 12349
>> statement: CREATE database essai;
>>
>> postgres=# CREATE database essai;
>> CREATE DATABASE
> Strange. Can you show me the result of "show pool_nodes"?
>
> Best regards,
> --
> Tatsuo Ishii
> SRA OSS, Inc. Japan
> English: http://www.sraoss.co.jp/index_en.php
> Japanese:http://www.sraoss.co.jp
>
postgres=# show pool_nodes;
 node_id |       hostname       | port | status | lb_weight |  role  |
select_cnt
---------+----------------------+------+--------+-----------+--------+------------
 0       | serv1.lesafrance.com | 5432 | 3      | 0.500000  | slave  | 0
 1       | serv2.lesafrance.com | 5432 | 2      | 0.500000  | master | 0
(2 lignes)

do you need pgpool.conf ?


More information about the pgpool-general mailing list