Thread: FreeBSD shared memory settings

FreeBSD shared memory settings

From
"Paul Khavkine"
Date:


Hi Guys.

I have a bit of a peculiar situation.

I have t move a PostgreSQL 7.3 installation from a freeBSD 4.8 to a FreeBSD 6.1.
I have PG 7.3 installed in a single directory, have moved the directory from one server to another. After instaling all the compat 4x and 5x libraries
everything seems to be ok, except when i start postmaster, the following error comes up:

IpcSemaphoreCreate: semget(key=5433001, num=17, 03600) failed: No space left on device

This error does *not* mean that you have run out of disk space.

It occurs when either the system limit for the maximum number of
semaphore sets (SEMMNI), or the system wide maximum number of
semaphores (SEMMNS), would be exceeded.  You need to raise the
respective kernel parameter.  Alternatively, reduce PostgreSQL's
consumption of semaphores by reducing its max_connections parameter
(currently 32).

The PostgreSQL Administrator's Guide contains more information about
configuring your system for PostgreSQL.


I have adjusted kernel settings for shared memory, but no go.
We have a native PG 8.1 on same machine (different port) working just fine.

Also the 7.3 install (FreeBSD 4.8 binary) has all default values in postgres.conf for FreeBSD 4.8.

Any ideas ?


Thanx
Paul

Re: FreeBSD shared memory settings

From
Jeff Davis
Date:
On Fri, 2006-12-15 at 13:54 -0500, Paul Khavkine wrote:
> IpcSemaphoreCreate: semget(key=5433001, num=17, 03600) failed: No
> space left on device
>
> I have adjusted kernel settings for shared memory, but no go.
> We have a native PG 8.1 on same machine (different port) working just
> fine.
>

Adjust the settings for semaphores. You probably want a high shared
memory setting as well, but that is not what is causing this particular
error.

Regards,
    Jeff Davis


Re: FreeBSD shared memory settings

From
Bill Moran
Date:
In response to "Paul Khavkine" <pkhavkine@gmail.com>:
>
> I have a bit of a peculiar situation.
>
> I have t move a PostgreSQL 7.3 installation from a freeBSD 4.8 to a FreeBSD
> 6.1.
> I have PG 7.3 installed in a single directory, have moved the directory from
> one server to another. After instaling all the compat 4x and 5x libraries
> everything seems to be ok, except when i start postmaster, the following
> error comes up:
>
> IpcSemaphoreCreate: semget(key=5433001, num=17, 03600) failed: No space left
> on device
>
> This error does *not* mean that you have run out of disk space.
>
> It occurs when either the system limit for the maximum number of
> semaphore sets (SEMMNI), or the system wide maximum number of
> semaphores (SEMMNS), would be exceeded.  You need to raise the
> respective kernel parameter.  Alternatively, reduce PostgreSQL's
> consumption of semaphores by reducing its max_connections parameter
> (currently 32).
>
> The PostgreSQL Administrator's Guide contains more information about
> configuring your system for PostgreSQL.
>
>
> I have adjusted kernel settings for shared memory, but no go.
> We have a native PG 8.1 on same machine (different port) working just fine.

Did you add the memory requirements for the two installations together
when you set the sysctls?  Use the ipcs command to see what you've got.

--
Bill Moran
Collaborative Fusion Inc.