From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | david(at)lang(dot)hm |
Cc: | Andrew Sullivan <ajs(at)commandprompt(dot)com>, pgsql-performance(at)postgresql(dot)org |
Subject: | Re: select on 22 GB table causes "An I/O error occured while sending to the backend." exception |
Date: | 2008-08-28 04:56:23 |
Message-ID: | 659.1219899383@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-performance |
david(at)lang(dot)hm writes:
> On Wed, 27 Aug 2008, Andrew Sullivan wrote:
>> The upshot of this is that postgres tends to be a big target for the
>> OOM killer, with seriously bad effects to your database. So for good
>> Postgres operation, you want to run on a machine with the OOM killer
>> disabled.
> I disagree with you.
Actually, the problem with Linux' OOM killer is that it
*disproportionately targets the PG postmaster*, on the basis not of
memory that the postmaster is using but of memory its child processes
are using. This was discussed in the PG archives a few months ago;
I'm too lazy to search for the link right now, but the details and links
to confirming kernel documentation are in our archives.
This is one hundred percent antithetical to the basic design philosophy
of Postgres, which is that no matter how badly the child processes screw
up, the postmaster should live to fight another day. The postmaster
basically exists to restart things after children die ungracefully.
If the OOM killer takes out the postmaster itself (rather than the child
that was actually eating the unreasonable amount of memory), we have no
chance of recovering.
So, if you want a PG installation that is as robust as it's designed to
be, you *will* turn off Linux' OOM killer. Otherwise, don't complain to
us when your database unexpectedly stops responding.
(Alternatively, if you know how an unprivileged userland process can
defend itself against such exceedingly brain-dead kernel policy, we are
all ears.)
regards, tom lane
PS: I think this is probably unrelated to the OP's problem, since he
stated there was no sign of any problem from the database server's
side.
From | Date | Subject | |
---|---|---|---|
Next Message | Craig James | 2008-08-28 05:58:51 | Re: select on 22 GB table causes "An I/O error occured while sending to the backend." exception |
Previous Message | Tom Lane | 2008-08-28 04:35:07 | Re: select on 22 GB table causes "An I/O error occured while sending to the backend." exception |