[Pgpool-general] pgpool show status used connections
Erik Jones
erik at myemma.com
Wed Nov 7 21:23:56 UTC 2007
Heiko, thanks for your response! It turned out to be client app
issues.
On Nov 7, 2007, at 6:22 AM, Heiko L. wrote:
> Hallo *!
>
> mission:
> - To the diagnosis a connecting-problem
> should be write "used number of connections" to logfile each 10 min.
>
> - version 3.1.1(kawakawa)
>
> - details s. "test log_connections_count"
>
> How to print-out "number of connections"?
>
> regards Heiko
>
> ----------------------------------------------------------------------
> -
> - test log_connections_count
>
> - add line pool_log to child.c:do_child()
>
> 411 if ( pool_config.child_max_connections > 0 )
> 412 connections_count++;
> 413
> 414 pool_log("do_child, add connection %d",
> connections_count);
> 415 /* check if maximum connections count for this
> child reached */
> 416 if ( ( pool_config.child_max_connections >
> 0 ) &&
> 417 ( connections_count >=
> pool_config.child_max_connections ) )
>
> # /etc/init.d/pgpool start
>
> Nov 7 08:33:25 mail pgpool: 2007-11-07 08:33:25 LOG: pid 14594:
> do_child, add connection 0
> ....
>
> Nov 7 09:25:07 mail pgpool: 2007-11-07 09:25:07 LOG: pid 15824:
> do_child, add connection 0
> Nov 7 09:25:07 mail pgpool: 2007-11-07 09:25:07 LOG: pid 16240:
> do_child, add connection 0
> Nov 7 09:25:07 mail pgpool: 2007-11-07 09:25:07 LOG: pid 16342:
> do_child, add connection 0
>
> - Result: connections_count is always eq 0
>
> - suggestion: variable connections_count is not defined as global.
> -> so that connections_count can be never ge 1
>
> - do_child() called by main.c:fork_a_child() only
>
>
> _______________________________________________
> Pgpool-general mailing list
> Pgpool-general at pgfoundry.org
> http://pgfoundry.org/mailman/listinfo/pgpool-general
Erik Jones
Software Developer | Emma®
erik at myemma.com
800.595.4401 or 615.292.5888
615.292.0777 (fax)
Emma helps organizations everywhere communicate & market in style.
Visit us online at http://www.myemma.com
More information about the Pgpool-general
mailing list