From: | Marek Florianczyk <franki(at)tpi(dot)pl> |
---|---|
To: | Gaetano Mendola <mendola(at)bigfoot(dot)com> |
Cc: | "pgsql-admin(at)postgresql(dot)org" <pgsql-admin(at)postgresql(dot)org> |
Subject: | Re: performance problem - 10.000 databases |
Date: | 2003-10-31 12:31:34 |
Message-ID: | 1067603494.22233.95.camel@franki-laptop.tpi.pl |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
W liście z pią, 31-10-2003, godz. 13:06, Gaetano Mendola pisze:
> Marek Florianczyk wrote:
>
> > But my problem is that when I hit command:
> > psql -h 127.0.0.1 dbname dbuser
> > I'm waiting about 3-5 sec to enter psql monitor, so every new connection
> > from apache will wait about 3-5 sec to put query to server. Thats a very
> > long time...
>
> Why don't you use a connection manager ?
What is connection manager?
In PostgreSQL related project I only found SQLB ( Load Balancer ) but
it's designed to use with one ( large ) database and maybe with more
than one PostgreSQL server.
The best solution for me, it would by small pogram installed on machine
with apache + php, php would have persistent connection to this small
program troghout unix socket, and client authorization would be done by
this program. This program would have some pool of connection to
PostgreSQL server. So apache could have let's say 3000 persistent
connection to this small program, but this program would have 100
connection to PostgreSQL server and thats enought to process all
queries. If traffic increase, clients, are already connected to local
socket, and more new (tcp/ip) connection to server are made if
necessery.
The only trick is that pg_hba.conf of the PostgreSQL server would have:
host any connectmanager ip_addr netmask md5
And the autorization of the 10.000 clients would be done by small
program istalled on apache server.
I've never heard about souch a software ;)
What is a connection manager ?
greetings
Marek
From | Date | Subject | |
---|---|---|---|
Next Message | Matt Clark | 2003-10-31 12:33:12 | Re: performance problem - 10.000 databases |
Previous Message | Marek Florianczyk | 2003-10-31 12:14:12 | Re: performance problem - 10.000 databases |