From: | Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com> |
---|---|
To: | Qiang Wang <forest_qiang(at)yahoo(dot)com> |
Cc: | "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org> |
Subject: | Re: Will shared_buffers crash a server |
Date: | 2011-04-29 10:34:38 |
Message-ID: | BANLkTikj7akJeSE6biLaAZ9vv-=BRfovPg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
On Fri, Apr 29, 2011 at 1:13 AM, Qiang Wang <forest_qiang(at)yahoo(dot)com> wrote:
>
> We have 10GB memory and we tuned PostgreSQL as follow:
> - max_connection = 100
> - work_mem = 50MB
You do know that work_mem is PER SORT right? Not per connection or
per user or per database. If all 100 of those connections needs to do
a large sort at once (unlikely but possible, especially if under heavy
load) then you could have pgsql trying to allocate 50000MB. If you
have the occasional odd jobs that really need 50MB work_mem then set
it for a single user or connection and leave the other users in the 1
to 4MB range until you can be sure you're not running your db server
out of memory.
> However we suffered 2 times server crashes after tunning the configuration.
> Does anyone have any idea how this can happen?
Look in your log files for clues. postgresql logs as well as system
logs. What exact symptoms, if any, can you tell us of the crash?
From | Date | Subject | |
---|---|---|---|
Next Message | French, Martin | 2011-04-29 10:37:31 | Re: {Spam} Will shared_buffers crash a server |
Previous Message | James Mansion | 2011-04-29 08:25:00 | Re: Performance |