Thread

  1. too many clients - Error message

    Joseph <lters@mrtc.com> — 2000-04-22T10:16:14Z

    How do you solve this error message?
    
    Connection to database 'template1' failed.
    Sorry, too many clients already
    
    
    Joseph 
    
    
    
  2. Re: too many clients - Error message

    Charles Tassell <ctassell@isn.net> — 2000-04-22T19:43:14Z

    The maximum number of backends that the PostGres postmaster will start is 
    32.  If you want more, you have to specify the maximum on the command line 
    with the -N option. IE, you can start postgres like this to allow internet 
    connections, have it fork into the background, and allow 100 simultaneous 
    connections:
    /usr/local/pgsql/bin/postmaster -i -B 256 -S -N 100
    
    At 07:16 AM 4/22/00, Joseph wrote:
    
    >How do you solve this error message?
    >
    >Connection to database 'template1' failed.
    >Sorry, too many clients already
    >
    >
    >Joseph
    
    
    
  3. RE: too many clients - Error message

    Charles Tassell <ctassell@isn.net> — 2000-04-26T16:56:27Z

    Depends on what you are using for clients.  For instance, many web 
    programming suites use "persistent connections."  Persistent connections 
    stay open in the hopes that the web server process will have need of them 
    again, and keeping them open will save  the time of reconnecting when that 
    occurs.  Only Apache with addons like mod_perl, Zope, or PHP will use 
    persistent connections.  In other clients, I would guess that the problem 
    is that the client isn't calling disconnect, either because it's idling, or 
    because the author forgot to code it in before the client exits.  I'm not 
    sure how long it takes PostGres to idle out a backend process, or if it 
    ever will.
    
    
    At 07:31 AM 4/26/00, Joseph wrote:
    >Thanks for the response.
    >
    >Why do the connections seem to build up?
    >How do you clear them?
    >Should not the client close the connection when finished?
    >Or see how many are out there?
    >
    > >The maximum number of backends that the PostGres postmaster will start is
    > >32.  If you want more, you have to specify the maximum on the command line
    > >with the -N option. IE, you can start postgres like this to allow internet
    > >connections, have it fork into the background, and allow 100 simultaneous
    > >connections:
    >
    > >/usr/local/pgsql/bin/postmaster -i -B 256 -S -N 100
    > >
    > >>At 07:16 AM 4/22/00, Joseph wrote:
    > >>
    > >>How do you solve this error message?
    > >>
    > >>Connection to database 'template1' failed.
    > >>Sorry, too many clients already
    >
    >
    >
    >Joseph