From: | Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com> |
---|---|
To: | Benoit Clennett-Sirois <benoit(at)lesite(dot)ca> |
Cc: | pgsql-admin(at)postgresql(dot)org, Mathieu Leduc <mathieu(dot)leduc(at)lesite(dot)ca> |
Subject: | Re: Postgres crash during low-traffic period, need advice. |
Date: | 2010-12-20 14:34:06 |
Message-ID: | AANLkTi=oTqL+2mq1fZV6xC+XZcvfnGjFVPidVF2pikjc@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
On Mon, Dec 20, 2010 at 6:41 AM, Benoit Clennett-Sirois
<benoit(at)lesite(dot)ca> wrote:
> Hi,
>
> We have a front-end server taking care of Nginx, memcached and
> Postgresql. Last night the postgres daemon crashed (traffic was very
> low at that time) with the following error:
>
> 2010-12-20 03:34:30 EST DETAIL: Failed system call was
> shmget(key=5432001, size=1124474880, 03600).
> 2010-12-20 03:34:30 EST HINT: This error usually means that
> PostgreSQL's request for a shared memory segment exceeded available
> memory or swap space. To reduce the request size (currently 1124474880
> bytes), reduce PostgreSQL's shared_buffers parameter (currently
> 131072) and/or its max_connections parameter (currently 963).
Are you sure this is the crash and not the symptom of a restart issue
or something?
I'd look more carefully through the logs for the PANIC that a crash
should cause. I'm guessing you got killed by the OOM killer. 4 Gigs
is pitiful for a multi-purpose db / web server, my son's laptop has 8
gigs. What do you have work_mem set to? A high setting there can be
quickly fatal since it's per-sort, not total.
Generally shared_buffers ~1Gig on a 4Gig machine would be reasonable
if it was just a db server. If it's shared with other stuff, drop it
down to the 100Meg range.
From | Date | Subject | |
---|---|---|---|
Next Message | Benoit Clennett-Sirois | 2010-12-20 15:46:16 | Re: Postgres crash during low-traffic period, need advice. |
Previous Message | lst_hoe02 | 2010-12-20 14:29:03 | Re: Postgres crash during low-traffic period, need advice. |