Well, I have this kind of log from pglb log<br>Thu May 29 16:54:21 2008&nbsp; PGRset_status_on_cluster_tbl():host:***.***.***.*** port:5432 max:3 use:0 status1<br>Thu May 29 16:54:21 2008&nbsp; PGRset_status_on_cluster_tbl():host:***.***.***.*** port:5432 max:3 use:0 status1<br>
Thu May 29 16:54:21 2008&nbsp; init_pglb():Child_Tbl size is[4644]<br>Thu May 29 16:55:16 2008&nbsp; PGRscan_cluster:2 ClusterDB can be used<br>Thu May 29 16:55:16 2008&nbsp; PGRscan_cluster:***.***.***.*** [5432],useFlag-&gt;1 max-&gt;3 use_num-&gt;0<br>
<br>Thu May 29 16:55:16 2008&nbsp; PGRset_status_on_cluster_tbl():host:***.***.***.*** port:5432 max:3 use:1 status2<br>Thu May 29 16:55:16 2008&nbsp; I am 880<br>Thu May 29 16:55:16 2008&nbsp; I am 880 accept fd 6<br>Thu May 29 16:55:16 2008&nbsp; Protocol Major: 1234 Minor: 5679 database:&nbsp; user:<br>
Thu May 29 16:55:16 2008&nbsp; PGRdo_child(): SSLRequest: sent N; retry startup<br>Thu May 29 16:58:04 2008&nbsp; PGRscan_cluster:2 ClusterDB can be used<br>Thu May 29 16:58:04 2008&nbsp; PGRscan_cluster:***.***.***.*** [5432],useFlag-&gt;2 max-&gt;3 use_num-&gt;0<br>
<br>Thu May 29 16:58:04 2008&nbsp; I am 882<br>Thu May 29 16:58:04 2008&nbsp; I am 882 accept fd 6<br>Thu May 29 16:58:04 2008&nbsp; Protocol Major: 1234 Minor: 5679 database:&nbsp; user:<br>Thu May 29 16:58:04 2008&nbsp; PGRdo_child(): SSLRequest: sent N; retry startup<br>
<br><br>I think load balancer detect two server and the number of max.<br>After that when I try to connect by 5433, it looks like trying to connect to one server. I think after that, there is some problem with ssl. Do I have to do something with ssl configuration?<br>
<br><br><div class="gmail_quote">On Wed, May 28, 2008 at 10:30 PM,  &lt;<a href="mailto:mitani@sraw.co.jp">mitani@sraw.co.jp</a>&gt; wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
<br>
The load balncer has current session numbers of each cluster db.<br>
The maximum session number of each cluster db is defined in &quot;pglb.conf&quot;.<br>
Then, load balancer consider the load as &quot;(connected sessions)/(max sessions)&quot;.<br>
It is consider neither connecting times nor cpu load.<br>
It is using just number of sessions.<br>
<br>
About the pg_connect error.<br>
Can you let us know the debug messages of replication server.<br>
Probably, we can find something in the debug log.<br>
<br>
Regards,<br>
--------------<br>
At.Mitani<br>
<div class="Ih2E3d"><br>
-- original message --<br>
From: Chahyeon Rhee&lt;<a href="mailto:rchyeon@gmail.com">rchyeon@gmail.com</a>&gt;<br>
To: &lt;<a href="mailto:pgcluster-general@pgfoundry.org">pgcluster-general@pgfoundry.org</a>&gt;<br>
Sent: Wed, 28 May 2008 17:03:31 -0600<br>
Subject: [Pgcluster-general] concept of load balance server<br>
<br>
&gt;Hi!<br>
&gt;I am setting up load balance and cluster db1 in server 1<br>
&gt;and replicator and cluster db2 in server 2.<br>
&gt;I just tested replication and restoration.<br>
&gt;Now, I would like to test load balance. But, I am little bit confused.<br>
&gt;What I am thinking &nbsp;is that I think if client request some then they will go<br>
&gt;to some page in server 1.<br>
&gt;Which is starting point. So I used pg_connect(host=server1 port=5433 dbname=<br>
&gt;... )<br>
&gt;What I am thinking is if that connection go to load balance server in port<br>
&gt;5433 then load balance server will determine which is lower load from<br>
&gt;server1 and server 2. Server 1 and server 2 has port 5432. And the selected<br>
&gt;database will be used for that service.<br>
&gt;Is that right ?<br>
&gt;If not, please give me any advice.<br>
&gt;Also when I am doing like this, I am getting this error message *<br>
&gt;Warning*: pg_connect()<br>
</div>&gt;[function.pg-connect&lt;<a href="http://seo.gkmc.utah.edu/cha_test/pgcluster/function.pg-connect" target="_blank">http://seo.gkmc.utah.edu/cha_test/pgcluster/function.pg-connect</a>&gt;]:<br>
<div class="Ih2E3d">&gt;Unable to connect to PostgreSQL server: server closed the connection<br>
&gt;unexpectedly This probably means the server terminated abnormally before or<br>
&gt;while processing the request.<br>
&gt;<br>
&gt;If you know about this, please give me some help.<br>
&gt;<br>
&gt;Thanks,<br>
&gt;<br>
</div>&gt;_______________________________________________<br>
&gt;Pgcluster-general mailing list<br>
&gt;<a href="mailto:Pgcluster-general@pgfoundry.org">Pgcluster-general@pgfoundry.org</a><br>
&gt;<a href="http://pgfoundry.org/mailman/listinfo/pgcluster-general" target="_blank">http://pgfoundry.org/mailman/listinfo/pgcluster-general</a><br>
&gt;<br>
<br>
_______________________________________________<br>
Pgcluster-general mailing list<br>
<a href="mailto:Pgcluster-general@pgfoundry.org">Pgcluster-general@pgfoundry.org</a><br>
<a href="http://pgfoundry.org/mailman/listinfo/pgcluster-general" target="_blank">http://pgfoundry.org/mailman/listinfo/pgcluster-general</a><br>
</blockquote></div><br>