Re: Increasing Max Connections Mac OS 10.3 - Mailing list pgsql-general

From Joe Lester
Subject Re: Increasing Max Connections Mac OS 10.3
Date
Msg-id F01B5959-5BD1-11D8-A8C6-000A95A58EA0@sweetwater.com
Whole thread Raw
In response to Re: Increasing Max Connections Mac OS 10.3  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Increasing Max Connections Mac OS 10.3  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
So the odd thing is, I came in this morning, reset my settings in
/etc/rc and it took this time! I am a little baffled since I tried
these same settings yesterday with no success. It's probably just me
being goofy. Here are the settings that took:

[lester2:~] joe% sysctl -a | grep sysv
kern.sysv.shmmax: 167772160
kern.sysv.shmmin: 1
kern.sysv.shmmni: 32
kern.sysv.shmseg: 8
kern.sysv.shmall: 65536

With shmmax set to 167772160 I am able to launch the server with 240
connections (set in postgresql.conf). That's a good thing. What worries
me though is that my postgres log keeps printing out messages, one
after the other, like:

2004-02-10 08:46:01 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:01 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:01 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:02 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:02 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:02 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:02 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:02 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:02 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:03 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:03 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:03 LOG:  out of file descriptors: Too many open files;
release and retry
2004-02-10 08:46:03 LOG:  out of file descriptors: Too many open files;
release and retry

Even though I'm getting these messages in my log, all the queries I
send to the server seem to be working. I'm using libpq to access the
server from a Cocoa client. My program seems to be working just fine in
spite of the "out of file descriptors" warnings I'm getting in the
postgres log. It makes me kind if hesitant to try it out with 240
users. What should I do to get rid of these log messages? I'm running
Postgres 7.4.1 on a dual G5 running Mac OS 10.3.2. Thanks.



On Feb 9, 2004, at 8:12 PM, Tom Lane wrote:

> Joe Lester <joe_lester@sweetwater.com> writes:
>> I tried a few different things to try to get the shmmax value to be
>> something other than 4194304 (the default in /etc/rc).
>
>> First, I restarted my mac, then, as the root user...
>
> You can't change shmmax on-the-fly in OS X --- that's why it's set up
> in
> /etc/rc before the system is fully operational.  AFAIK the *only* way
> to
> change these parameters is edit /etc/rc and reboot.
>
>             regards, tom lane
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 8: explain analyze is your friend
>



pgsql-general by date:

Previous
From: "veramente@libero.it"
Date:
Subject: Strange Slow query
Next
From: Bruce Momjian
Date:
Subject: Re: [BUGS] Probably a security bug in PostgreSQL rule system