[Pgpool-general] can't attach two nodes simultaneously
Tatsuo Ishii
ishii at sraoss.co.jp
Thu Apr 15 04:34:17 UTC 2010
> I noticed trying to attach two nodes with such commands:
>
> pcp_attach_node -d 5 127.0.0.1 9898 user pass 0 ; pcp_attach_node -d 5 127.0.0.1 9898 user pass 1
>
>
> will fail with:
>
> pgpool: 2010-04-14 03:44:59 ERROR: pid 4270: failover_handler: invalid node_id -1 status:1 MAX_NUM_BACKENDS: 128
>
>
> On the other hand, adding sleep in between makes it succeed:
>
> pcp_attach_node -d 5 127.0.0.1 9898 user pass 0 ; sleep 1; pcp_attach_node -d 5 127.0.0.1 9898 user pass 1
>
>
> But with "sleep", it's even less "atomic" then the first command.
>
>
> My question:
>
> 1. Is it expected that it fails when we start pcp_attch_node one after another?
No. I will look into this.
> 2. Is there a way to attach multiple nodes in an "atomic" way?
Why do you need atomicity for this?
--
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