Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 11 Feb 2000 11:41:45 -0500 (EST)
From:      Brian Dean <brdean@unx.sas.com>
To:        Andrey Novikov <novikov@webclub.ru>
Cc:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: Tuning up semaphores in kernel
Message-ID:  <200002111641.LAA48618@dean.pc.sas.com>
In-Reply-To: <00021114101000.00662@newbee.web2000.ru> from Andrey Novikov at "Feb 11, 2000 02:01:49 pm"

next in thread | previous in thread | raw e-mail | index | archive | help
Take a look at:

sys/conf/param.c:

/*
 * Values in support of System V compatible semaphores.
 */

#ifdef SYSVSEM

struct seminfo seminfo = {
                SEMMAP,         /* # of entries in semaphore map */
                SEMMNI,         /* # of semaphore identifiers */
                SEMMNS,         /* # of semaphores in system */
                SEMMNU,         /* # of undo structures in system */
                SEMMSL,         /* max # of semaphores per id */
                SEMOPM,         /* max # of operations per semop call */
                SEMUME,         /* max # of undo entries per process */
                SEMUSZ,         /* size in bytes of undo structure */
                SEMVMX,         /* semaphore maximum value */
                SEMAEM          /* adjust on exit max value */
};
#endif

You probably want to increase either SEMMNI or SEMMNS.

Andrey Novikov wrote:
> Resently my PostgreSQL daemon died with:
> IpcSemaphoreCreate: semget failed (No space left on device) key=5432015, num=16, permission=600
> 
> I figured out that the kernel is out of available semaphores,
> I wanted to rebuild it but the problem is that the options
> related to semaphores are not documented. This is the mission
> critical commercial server so I don't want just to make assumptions.
> Can you please tell me how these all enigmatic numbers are
> properly choosed:
> options         SEMMAP=31
> options         SEMMNI=11
> options         SEMMNS=61
> options         SEMMNU=31
> options         SEMMSL=61
> options         SEMOPM=101
> options         SEMUME=11


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200002111641.LAA48618>