I have a fatal error message while connecting more than 32 users using
current:

	Aug 29 11:25:18 srapc1474 postgres[12189]: [1] FATAL 1:
	ProcGetNewSemIdAndNum: cannot allocate a free semaphore

rather than a more informative message:

       Sorry, too many clients already

Does anynbody know what's happening?
--
Tatsuo Ishii

Wed, 29 Aug 2001 11:31:54 +0900
Tatsuo Ishii <t-ishii@sra.co.jp>
cannot detect too many clients
>From that error below it looks to me that you will need to recompile your
kernel (or whatever) to add support for more shared memory and more shared
semaphores.

Try this URL:

http://www.ca.postgresql.org/devel-corner/docs/admin/kernel-resources.html

Chris

> -----Original Message-----
> From: pgsql-hackers-owner@postgresql.org
> [mailto:pgsql-hackers-owner@postgresql.org]On Behalf Of Tatsuo Ishii
> Sent: Wednesday, 29 August 2001 10:32 AM
> To: pgsql-hackers@postgresql.org
> Subject: [HACKERS] cannot detect too many clients
>
>
> I have a fatal error message while connecting more than 32 users using
> current:
>
> 	Aug 29 11:25:18 srapc1474 postgres[12189]: [1] FATAL 1:
> 	ProcGetNewSemIdAndNum: cannot allocate a free semaphore
>
> rather than a more informative message:
>
>        Sorry, too many clients already
>
> Does anynbody know what's happening?
> --
> Tatsuo Ishii
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>


Wed, 29 Aug 2001 11:06:21 +0800
"Christopher Kings-Lynne" <chriskl@familyhealth.com.au>
RE: cannot detect too many clients
> >From that error below it looks to me that you will need to recompile your
> kernel (or whatever) to add support for more shared memory and more shared
> semaphores.

My point is 7.1 or earlier behaves different from current. 7.1 or
earlier's postmaster won't start if there is not enough shared memory
and semaphores.

I just want to know if that's a intended behavior.
--
Tatsuo Ishii


Wed, 29 Aug 2001 12:42:31 +0900
Tatsuo Ishii <t-ishii@sra.co.jp>
RE: cannot detect too many clients
Tatsuo Ishii <t-ishii@sra.co.jp> writes:
> I have a fatal error message while connecting more than 32 users using
> current:

> 	Aug 29 11:25:18 srapc1474 postgres[12189]: [1] FATAL 1:
> 	ProcGetNewSemIdAndNum: cannot allocate a free semaphore

> rather than a more informative message:

>        Sorry, too many clients already

> Does anynbody know what's happening?

Ugh.  I thought I'd tested that.  The problem is that it runs out of
semaphores before noting that there's no free slots in the PROC array
(which is where the "more informative" message was supposed to come
out).  Need to rearrange the order of operations, or some such.
Will fix.

			regards, tom lane

Mon, 03 Sep 2001 14:22:03 -0400
Tom Lane <tgl@sss.pgh.pa.us>
Re: cannot detect too many clients 
I wrote:
> Tatsuo Ishii <t-ishii@sra.co.jp> writes:
>> I have a fatal error message while connecting more than 32 users using
>> current:
>> Aug 29 11:25:18 srapc1474 postgres[12189]: [1] FATAL 1:
>> ProcGetNewSemIdAndNum: cannot allocate a free semaphore
>> rather than a more informative message:
>> Sorry, too many clients already
>> Does anynbody know what's happening?

> Ugh.  I thought I'd tested that.

Indeed I had, but I'd used a low value of MaxBackends to test it.
If MaxBackends is a multiple of PROC_NSEMS_PER_SET (16) then too-many-
backends will be detected here, not later on when we try to insert our
PROC entry into the sinval array.  Whoops.  Fix committed.

			regards, tom lane

Wed, 05 Sep 2001 23:05:21 -0400
Tom Lane <tgl@sss.pgh.pa.us>
Re: cannot detect too many clients 