[pgpool-general: 5481] Re: max_pool parameter question (again!)

Piotr Gbyliczek P.Gbyliczek at node4.co.uk
Wed May 17 17:44:53 JST 2017


On Monday, 15 May 2017 18:58:45 BST Pierre Timmermans wrote:
> Hi,
> This question was asked recently (thread 5439) but I don't understand the
> answer (I cannot reply to this thread because I was not yet subscribed). So
> I still cannot understand when the  max_pool parameter is taken into
> consideration by pgpool Like in the initial question, I experimented with
> num_init_children=1 and max_pool=2 If I connect with userA, then obviously
> it works. Then, in another window, I connect with userB : but it hangs
> (until I disconnect userA). My understanding of max_pool was that each
> children could cache 2 connections, one for each database user.


You are missing the fact that num_init_children limits your connections from 
client to pgpool. Each child can serve one connection in at the time.

So, you have 2 connection pools to backend servers, but you only allow one 
connection to pgpool, making the second pool utterly pointless. 

Number of pools regulates how often the new connection will benefit from 
already open cached connection to backend, or in other words, how often it 
will suffer from the delay of new backend connections being established. 

For example, if you have an user connecting to 3 databases, then you have 3 
distinctive user/database pairs. It would be best to set max_pool to 3. 
Setting it at 2 as above means that there is 33% chance that new connection 
will have to be established to backend servers (and it will be cached as such 
from that moment).

Regards,
Piotr
--

Piotr Gbyliczek
Solutions Engineer

Node4 Ltd, The POD, 10 Bottle Ln, Nottingham NG1 2HL
ddi. 08454 210444 | t. 0845 123 2222
e. P.Gbyliczek at node4.co.uk



Node4 Limited is registered in England No: 04759927 and has its registered office at Millennium Way, Pride Park, Derby, DE24 8HZ
The information contained in this email is confidential and is intended for the exclusive use of the email addressee shown.
If you are not the addressee, any disclosure, reproduction, distribution or other dissemination or use of this communication is strictly prohibited.
If you have received this mail in error, please notify our mail manager at abuse at node4.co.uk and delete it from your system.
Opinions expressed in this email are those of the individual not the company, unless specifically indicated to that effect.

This email has been scanned inbound by Node4's Email Security System.

This email message has been delivered safely and archived online by Mimecast.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445602145.png
Type: image/png
Size: 1315 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0006.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445602345.png
Type: image/png
Size: 16076 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0007.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445602545.png
Type: image/png
Size: 16233 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0008.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445602745.png
Type: image/png
Size: 17391 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0009.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445602945.jpg
Type: image/jpeg
Size: 21109 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0002.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445603145.jpg
Type: image/jpeg
Size: 29300 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0003.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445603345.png
Type: image/png
Size: 16168 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0010.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 117051709445603545.png
Type: image/png
Size: 19451 bytes
Desc: not available
URL: <http://www.sraoss.jp/pipermail/pgpool-general/attachments/20170517/74fe036d/attachment-0011.png>


More information about the pgpool-general mailing list