Author: Dan
Date: 29-11-06 13:32
Ever had this happen?
# /usr/local/etc/rc.d/010.pgsql.sh start
could not start postmaster
Check /var/log/messages:
Nov 29 08:29:15 bast postgres[3937]: [1-1] FATAL: could not create semaphores: No space left on device
Nov 29 08:29:15 bast postgres[3937]: [1-2] DETAIL: Failed system call was semget(5432003, 17, 03600).
Nov 29 08:29:15 bast postgres[3937]: [1-3] HINT: This error does *not* mean that you have run out of disk space.
Nov 29 08:29:15 bast postgres[3937]: [1-4] It occurs when either the system limit for the maximum number of semaphore sets (SEMMNI), or the system wide maximum number of
Nov 29 08:29:15 bast postgres[3937]: [1-5] semaphores (SEMMNS), would be exceeded. You need to raise the respective kernel parameter. Alternatively, reduce PostgreSQL's
Nov 29 08:29:15 bast postgres[3937]: [1-6] consumption of semaphores by reducing its max_connections parameter (currently 40).
Nov 29 08:29:15 bast postgres[3937]: [1-7] The PostgreSQL documentation contains more information about configuring your system for PostgreSQL.
For me, on my production database server, I added the following entries to /etc/loader.conf and rebooted.
kern.ipc.semmni=40
kern.ipc.semmns=240
kern.ipc.semmnu=60
kern.ipc.semmap=120
The reboot is necessary because some of the above knobs cannot be set at run time:
[root@bast:/boot] # sysctl -w kern.ipc.semmni=40
sysctl: oid 'kern.ipc.semmni' is a read only tunable
sysctl: Tunable values are set in /boot/loader.conf
[root@bast:/boot] # sysctl -w kern.ipc.semmns=240
sysctl: oid 'kern.ipc.semmns' is a read only tunable
sysctl: Tunable values are set in /boot/loader.conf
[root@bast:/boot] # sysctl -w kern.ipc.semmnu=60
sysctl: oid 'kern.ipc.semmnu' is a read only tunable
sysctl: Tunable values are set in /boot/loader.conf
[root@bast:/boot] # sysctl -w kern.ipc.semmap=120
kern.ipc.semmap: 30 -> 120
Enjoy
--
Webmaster
|
|