X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 3B75B40C1E5 for ; Sun, 30 Jan 2005 20:52:09 +0000 (GMT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 03434-04 for ; Sun, 30 Jan 2005 20:52:03 +0000 (GMT) Received: from jalapeno.crazydogs.org (jalapeno.jellybean.co.uk [212.78.70.100]) by svr1.postgresql.org (Postfix) with ESMTP id 2B42B40C1DE for ; Sun, 30 Jan 2005 20:50:21 +0000 (GMT) Received: from rp by jalapeno.crazydogs.org with local (Exim 3.36 #1 (Debian)) id 1CvM1V-0004mI-00; Sun, 30 Jan 2005 20:50:21 +0000 Date: Sun, 30 Jan 2005 20:50:21 +0000 From: Richard Poole To: pgsql-general@postgresql.org Cc: Rick Apichairuk Subject: Re: FreeBSD 5.2.1, postgresql 7.4.5 and shared memory settings Message-ID: <20050130205021.GA14588@guests.deus.net> References: <9776bb66050130122122a3e342@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9776bb66050130122122a3e342@mail.gmail.com> User-Agent: Mutt/1.5.4i X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.206 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200501/1757 X-Sequence-Number: 72706 On Sun, Jan 30, 2005 at 03:21:25PM -0500, Rick Apichairuk wrote: > I am trying to increase the number of max_connections to 200 and found > out I couldn't even start postgresql. So I tried to increase > max_connections gradually (currently at 50 from 40 default) and adjust > shared memory settings along the way. Even at 50 max_connections, I > still cannot get postgresql to start. > > The following is the error message I receive: > > pgsql FATAL: could not create shared memory segment: Invalid argument > DETAIL: Failed system call was shmget(key=5432001, size=35323904, > 03600). > To reduce the request size (currently 35323904 bytes), > kern.ipc.shmmax: 33554432 Looks like the request size is just higher than shmmax. The majority of the request is for the shared buffers, so if you can't increase shmmax any more you can reduce your shared buffers downwards from 4096 and this will give you some room for more connections. Richard