Hi,
I have postgres 8.0.2 installed on FreeBSD FreeBSD 4.11-RELEASE with 2GB
of RAM.
When trying to set max_connections=256 I get the following error message:
FATAL: could not create semaphores: No space left on device
DETAIL: Failed system call was semget(5432017, 17, 03600).
HINT: 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 256).
The PostgreSQL documentation contains more information about
configuring your system for PostgreSQL.
I have read through the kernel resources documentation for postgres 8
and set values accordingly.
Some settings are not staying after a reboot, even if I place them in
/boot/loader.conf.
So far I'm able to get max_connections to 250.
Here is a dump of kern.ipc values:
kern.ipc.maxsockbuf: 262144
kern.ipc.sockbuf_waste_factor: 8
kern.ipc.somaxconn: 128
kern.ipc.max_linkhdr: 16
kern.ipc.max_protohdr: 60
kern.ipc.max_hdr: 76
kern.ipc.max_datalen: 136
kern.ipc.nmbclusters: 65536
kern.ipc.msgmax: 16384
kern.ipc.msgmni: 40
kern.ipc.msgmnb: 2048
kern.ipc.msgtql: 40
kern.ipc.msgssz: 8
kern.ipc.msgseg: 2048
kern.ipc.semmap: 30
kern.ipc.semmni: 256
kern.ipc.semmns: 272
kern.ipc.semmnu: 30
kern.ipc.semmsl: 60
kern.ipc.semopm: 100
kern.ipc.semume: 10
kern.ipc.semusz: 92
kern.ipc.semvmx: 32767
kern.ipc.semaem: 16384
kern.ipc.shmmax: 33554432
kern.ipc.shmmin: 1
kern.ipc.shmmni: 192
kern.ipc.shmseg: 128
kern.ipc.shmall: 8192
kern.ipc.shm_use_phys: 0
kern.ipc.shm_allow_removed: 0
kern.ipc.mbuf_wait: 32
kern.ipc.mbtypes: 38 551 3 0 0 0 0 0 0 0 0 0 0 0 0 0
kern.ipc.nmbufs: 262144
kern.ipc.nsfbufs: 8704
kern.ipc.nsfbufspeak: 7
kern.ipc.nsfbufsused: 0
kern.ipc.m_clreflimithits: 0
kern.ipc.mcl_pool_max: 0
kern.ipc.mcl_pool_now: 0
kern.ipc.maxsockets: 65536
And boot/loader.conf:
userconfig_script_load="YES"
kern.ipc.nmbclusters="65536"
kern.maxfiles="65536"
kern.maxfilesperproc="65536"
net.inet.tcp.mssdflt="1460"
kern.somaxconn="4096"
kern.ipc.semmns="272"
kern.ipc.semmni="256"
kern.ipc.shmmax="66099200"
kern.ipc.shmmax and kern.ipc.shmmin will not stay to what I set them to.
What am I doing wrong or not doing at all?
Your help is greatly appreciated.
Regards,
Chris.
--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.308 / Virus Database: 266.11.2 - Release Date: 5/2/2005