From: Tom Lane <tgl@sss.pgh.pa.us>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Gurjeet Singh <gurjeet@singh.im>
Cc: Peter Eisentraut <peter_e@gmx.net>
Cc: PGSQL Hackers <pgsql-hackers@postgresql.org>
Subject: Re: /proc/self/oom_adj is deprecated in newer Linux kernels
Date: Tue, 10 Jun 2014 11:14:43 -0400
Message-ID: <30601.1402413283@sss.pgh.pa.us> (raw)
In-Reply-To: <CA+TgmoZ2tDAVB5cLPt=UKHaogw+cfq6ZEis1yCTD_gsBWud9SA@mail.gmail.com>
References: <29121.1316185073@sss.pgh.pa.us>
<1316355543.12186.9.camel@vanquo.pezone.net>
<15953.1316362868@sss.pgh.pa.us>
<1316420754.14001.3.camel@fsopti579.F-Secure.com>
<16241.1316441883@sss.pgh.pa.us>
<CABwTF4XDdYiBQXqj=CKrFXN7x2NiBbVnpHSJG6AVnMBLnLBmLA@mail.gmail.com>
<28946.1402408948@sss.pgh.pa.us>
<CA+Tgmoaps4ih-VEKvUgftqJ66_oSo-h9PpHi2_-wAzhVTYnzYw@mail.gmail.com>
<30117.1402411876@sss.pgh.pa.us>
<CA+TgmoZ2tDAVB5cLPt=UKHaogw+cfq6ZEis1yCTD_gsBWud9SA@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Robert Haas <robertmhaas@gmail.com> writes:
> On Tue, Jun 10, 2014 at 10:51 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> So? The RPM packager could probably be expected to have compiled with the
>> oom-adjust-reset option enabled. If not, why aren't these people lobbying
>> the packager to meet their expectation?
> Because that might take years to happen,
... unlike adding a GUC?
> or the packager might never
> do it at all on the theory that what is good for customers in general
> is different than what's good for one particular customer, or on the
> theory that it's just not a high enough priority for that packager.
> Are you seriously saying that you've never needed to customize a
> startup script on a RHEL box somewhere?
Sure, but what's that have to do with this? Any Red Hat or PGDG RPM will
come with this code already enabled in the build, so there is no need for
anyone to have a GUC to play around with the behavior.
>> I remain of the opinion that allowing nonprivileged people to decide
>> whether that code is active or not is unsafe from a system level.
> On what factual basis?
Because it would convert the intended behavior (postmaster and only
postmaster is exempt from OOM kill) into a situation where possibly
all of the database processes are exempt from OOM kill, at the whim
of somebody who should not have the privilege to decide that.
In my view, the root-owned startup script grants OOM exemption to
the postmaster because it *knows* that the postmaster's children
will drop the exemption. If that trust can be violated because some
clueless DBA decided to frob a GUC setting, I'd be a lot more hesitant
about giving the postmaster the exemption in the first place.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, robertmhaas@gmail.com, gurjeet@singh.im, peter_e@gmx.net
Subject: Re: /proc/self/oom_adj is deprecated in newer Linux kernels
In-Reply-To: <30601.1402413283@sss.pgh.pa.us>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox