Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id CDA041337C07 for ; Fri, 22 Apr 2011 13:46:04 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 75149-03-4 for ; Fri, 22 Apr 2011 16:45:56 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-qy0-f181.google.com (mail-qy0-f181.google.com [209.85.216.181]) by mail.postgresql.org (Postfix) with ESMTP id 6744B1337C11 for ; Fri, 22 Apr 2011 13:45:47 -0300 (ADT) Received: by qyg14 with SMTP id 14so378289qyg.19 for ; Fri, 22 Apr 2011 09:45:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-type:content-transfer-encoding; bh=lIyS8Ip4784gr9ISqlvhic81hb93qYjG7T7lBE3xdBw=; b=GpaHWmRWxN1qX0pEkkSDE86n5deYRNHQtQf1A8mXPI3WM8EVXtf2daeWg8kh0mn4/R 5ZxfUjvoVmnyh5POjpZ0Smlo5m6l70+8MS9JqVKfuG3QXTIpwCTOudBoKjQDF0F/vb2m iy70Lxf10ld/6ZAG7Bs1+HEfF9vCZtoy7GQK0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=L2fPzHU0E45ssu6aHysljzh3JUz2A3dM4XyUuVZ2nxwcs3bqhV62bGcxP4ITCkzWWs YIpqZNjfB/mWkqXiepnjyf6gEBbvyycsR3Q9DubEZZlMiDBKx4ib1Rs5qHNVd/jjTO5m KbRxbX7rMkPZf8m6EX0VsQFLprnIFgebNY4z8= Received: by 10.229.45.147 with SMTP id e19mr979247qcf.75.1303490745143; Fri, 22 Apr 2011 09:45:45 -0700 (PDT) MIME-Version: 1.0 Received: by 10.229.98.10 with HTTP; Fri, 22 Apr 2011 09:45:25 -0700 (PDT) In-Reply-To: References: From: =?ISO-8859-1?Q?C=E9dric_Villemain?= Date: Fri, 22 Apr 2011 18:45:25 +0200 Message-ID: Subject: Re: oom_killer To: Tory M Blue Cc: Merlin Moncure , pgsql-performance@postgresql.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.898 tagged_above=-10 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, RFC_ABUSE_POST=0.001 X-Spam-Level: X-Archive-Number: 201104/320 X-Sequence-Number: 43382 2011/4/22 Tory M Blue : > On Fri, Apr 22, 2011 at 4:03 AM, C=E9dric Villemain > wrote: >> 2011/4/21 Tory M Blue : >>> On Thu, Apr 21, 2011 at 7:27 AM, Merlin Moncure wr= ote: >>>> On Thu, Apr 21, 2011 at 3:28 AM, Tory M Blue wrote: >>> >>>>> Fedora 12 >>>>> 32gig memory, 8 proc >>>>> postgres 8.4.4, slony 1.20 >>>>> 5 gigs of swap (never hit it!) >>>> >>>> curious: using 32/64 bit postgres? what are your postgresql.conf >>>> memory settings? >>>> >>>> merlin >>>> >>> >>> 32bit >>> 32gb >>> PAE kernel >>> >>> # - Checkpoints - >>> checkpoint_segments =3D 100 >>> max_connections =3D 300 >>> shared_buffers =3D 2500MB =A0 =A0 =A0 # min 128kB or max_connections*16= kB >>> max_prepared_transactions =3D 0 >>> work_mem =3D 100MB >>> maintenance_work_mem =3D 128MB >>> fsync =3D on >>> >> >> I didn't understand what value you set for vm.overcommit parameters. >> Can you give it and the values in /proc/meminfo, the interesting one >> are "Commit*" ? >> >> If you have strict rules(overcommit=3D2), then your current kernel >> config may need some love : the commit_limit is probably too low >> because you have a small swap partition. One way is to change : >> vm.overcommit_ratio. >> By default it should be something like 21GB (0.5*32+5) of >> commit_limit, and you probably want 32GB :) >> >> Maybe you have some minor changes in your install or application usage >> and you just hit the limit. > > Thanks Cedric > > the sysctl vm's are > > # 04/17/2011 to keep overcommit memory in check > vm.overcommit_memory =3D 2 > vm.overcommit_ratio =3D 0 > > CommitLimit: =A0 =A0 4128760 kB > Committed_AS: =A0 =A02380408 kB Are you sure it is a PAE kernel ? You look limited to 4GB. I don't know atm if overcommit_ratio=3D0 has a special meaning, else I would suggest to update it to something like 40% (the default), but 60% should still be safe (60% of 32GB + 5GB) > > > Ya I do think my swap space is biting us, (but again just starting to > grasp that my swap space which has not grown with the continued > addition of memory). I am just not starting to learn that the swap > does need to be properly sized whether it's being used or not. I > figured it would use the swap and it would run out, but sounds like > the system takes the size into consideration and just decides not to > use it. > > I appreciate the totally no postgres responses with this. > > Thanks > Tory > --=20 C=E9dric Villemain=A0 =A0 =A0 =A0 =A0 =A0 =A0=A0 2ndQuadrant http://2ndQuadrant.fr/=A0 =A0=A0 PostgreSQL : Expertise, Formation et Suppo= rt