Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id BB05E1337BD8 for ; Fri, 11 Mar 2011 08:54:40 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 45885-07 for ; Fri, 11 Mar 2011 12:54:33 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from momjian.us (momjian.us [70.90.9.53]) by mail.postgresql.org (Postfix) with ESMTP id 9E3FA1337BC2 for ; Fri, 11 Mar 2011 08:54:32 -0400 (AST) Received: (from bruce@localhost) by momjian.us (8.11.6/8.11.6) id p2BCsHx20456; Fri, 11 Mar 2011 07:54:17 -0500 (EST) From: Bruce Momjian Message-Id: <201103111254.p2BCsHx20456@momjian.us> Subject: Re: Change to kernel-resources In-Reply-To: To: Robert Haas Date: Fri, 11 Mar 2011 07:54:17 -0500 (EST) CC: Josh Berkus , pgsql-docs@postgresql.org X-Mailer: ELM [version 2.4ME+ PL124 (25)] MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="ELM1299848057-10557-3_" Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-5 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201103/78 X-Sequence-Number: 6511 --ELM1299848057-10557-3_ Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="US-ASCII" Robert Haas wrote: > On Wed, Mar 2, 2011 at 2:46 PM, Josh Berkus wrote: > > On 3/2/11 8:35 AM, Robert Haas wrote: > >> On Mon, Feb 7, 2011 at 1:47 PM, Josh Berkus wrote: > >>> Had to look up some stuff given the splintering of Solaris: > >>> > >>> ================== > >>> > >>> Solaris 2.6 to 2.9 (Solaris 6 to Solaris 9) > >>> > >>> ? ?The default maximum size of a shared memory segment is too low for > >>> PostgreSQL. The relevant settings can be changed in /etc/system, for > >>> example: > >> > >> What should we do with this material? > > > > Hmmm. ?I think there are probably still people using Solaris 9 out > > there, but not very many. > > > > Maybe we should move obscure OSes to the wiki, and have a link to the > > wiki in the docs? > > I've got no problem putting it in the docs; in fact, I'd prefer it. > But it'd be a lot easier to put it there if this were in the form of a > patch. I did the markup and applied the attached doc patch. -- Bruce Momjian http://momjian.us EnterpriseDB http://enterprisedb.com + It's impossible for everything to be true. + --ELM1299848057-10557-3_ Content-Transfer-Encoding: 7bit Content-Type: text/x-diff Content-Disposition: inline; filename="/rtmp/solaris.diff" diff --git a/doc/src/sgml/runtime.sgml b/doc/src/sgml/runtime.sgml new file mode 100644 index 4a989df..c369229 *** a/doc/src/sgml/runtime.sgml --- b/doc/src/sgml/runtime.sgml *************** sysctl -w kern.sysv.shmall *** 1028,1041 **** ! Solaris SolarisIPC configuration ! At least in version 2.6, the default maximum size of a shared ! memory segment is too low for PostgreSQL. The ! relevant settings can be changed in /etc/system, ! for example: set shmsys:shminfo_shmmax=0x2000000 set shmsys:shminfo_shmmin=1 --- 1028,1041 ---- ! Solaris 2.6 to 2.9 (Solaris ! 6 to Solaris 9) SolarisIPC configuration ! The default maximum size of a shared memory segment is too low for ! PostgreSQL. The relevant settings can be changed in ! /etc/system, for example: set shmsys:shminfo_shmmax=0x2000000 set shmsys:shminfo_shmmin=1 *************** set semsys:seminfo_semmni=512 *** 1047,1060 **** set semsys:seminfo_semmns=512 set semsys:seminfo_semmsl=32 ! You need to reboot for the changes to take effect. ! See also ! for information on shared memory under ! Solaris. --- 1047,1105 ---- set semsys:seminfo_semmns=512 set semsys:seminfo_semmsl=32 ! You need to reboot for the changes to take effect. See also ! ! for information on shared memory under older versions of Solaris. + + + + Solaris 2.10 (Solaris + 10) + OpenSolaris + SolarisIPC configuration + ! In Solaris 10 and OpenSolaris, the default shared memory and ! semaphore settings are good enough for most ! PostgreSQL applications. Solaris now defaults ! to a SHMMAX of one-quarter of system RAM. If ! you need to increase this in order to set shared memory settings ! slightly higher, you should use a project setting associated ! with the postgres user. For example, run the ! following as root: ! ! projadd -c "PostgreSQL DB User" -K "project.max-shm-memory=(privileged,8GB,deny)" -U postgres -G postgres user.postgres ! ! ! ! ! This command adds the user.postgres project and ! raises the shared memory maximum for the postgres ! user to 8GB, and takes effect the next time that user logs ! in, or when you restart PostgreSQL (not reload). ! The above assumes that PostgreSQL is run by ! the postgres user in the postgres ! group. No server reboot is required. ! ! ! ! Other recommended kernel setting changes for database servers which will ! have a large number of connections are: ! ! project.max-shm-ids=(priv,32768,deny) ! project.max-sem-ids=(priv,4096,deny) ! project.max-msg-ids=(priv,4096,deny) ! ! ! ! ! Additionally, if you are running PostgreSQL ! inside a zone, you may need to raise the zone resource usage ! limits as well. See "Chapter2: Projects and Tasks" in the ! Solaris 10 System Administrator's Guide for more ! information on projects and prctl. --ELM1299848057-10557-3_--