[pgpool-general: 2428] Re: pgpool connections: FATAL: sorry, too many clients already

Tatsuo Ishii ishii at postgresql.org
Thu Jan 16 09:25:17 JST 2014


> Hi!
> 
> It seems I ran into another problem.
> 
> I have pgpool 3.3.1 with 2 postgresql 9.3 backends with streaming replication. I'm trying to set the correct number of allowed connections.
> 
> These are settings from postgresl.conf on both postgresql backends:
> 
> max_connections               = 30
> superuser_reserved_connections = 3
> 
> 
> These are settings from pgpool.conf:
> 
> num_init_children             = 25
> max_pool                      = 2
> 
> I set these values according to the following formula:
> 
> max_pool*num_init_children <= (max_connections - superuser_reserved_connections) 
> 
> 2 * 25 <= ( 30 - 3 )*2

Where does the caliculation come from?
Isn't that should be:

2 * 25 <= ( 30 - 3 )

and it is going to be false.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese: http://www.sraoss.co.jp

> When both backends are online everything goes without any problems. Both backends have equal number of connections and everything works well. But once one of the backends goes offline I instantly start getting the following error on the online backend: 
> 
> FATAL:  sorry, too many clients already
> 
> and then it goes offline as well. pgpool shows this error message:
> 
> Cannot accept() new connection. all backends are down
> 
> It seems pgpool tries to use the whole bunch of allowed connections (2*25) against only one backend (with 27 allowed connections).
> 
> Could you please tell how to avoid this error? 
> 
> Thanks in advance. 
> 
> 
> --
> Best regards,
> Sergey Arlashin
> 
> 
> _______________________________________________
> pgpool-general mailing list
> pgpool-general at pgpool.net
> http://www.pgpool.net/mailman/listinfo/pgpool-general


More information about the pgpool-general mailing list