Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WuNlG-0001Mm-LA for pgsql-hackers@arkaria.postgresql.org; Tue, 10 Jun 2014 15:14:54 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WuNlG-0000yQ-4j for pgsql-hackers@arkaria.postgresql.org; Tue, 10 Jun 2014 15:14:54 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1WuNlE-0000y8-S1 for pgsql-hackers@postgresql.org; Tue, 10 Jun 2014 15:14:52 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:DHE_RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1WuNlB-0004Rp-EA for pgsql-hackers@postgresql.org; Tue, 10 Jun 2014 15:14:51 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id s5AFEhkJ030602; Tue, 10 Jun 2014 11:14:43 -0400 From: Tom Lane To: Robert Haas cc: Gurjeet Singh , Peter Eisentraut , PGSQL Hackers Subject: Re: /proc/self/oom_adj is deprecated in newer Linux kernels In-reply-to: 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> <28946.1402408948@sss.pgh.pa.us> <30117.1402411876@sss.pgh.pa.us> Comments: In-reply-to Robert Haas message dated "Tue, 10 Jun 2014 10:56:48 -0400" Date: Tue, 10 Jun 2014 11:14:43 -0400 Message-ID: <30601.1402413283@sss.pgh.pa.us> X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Robert Haas writes: > On Tue, Jun 10, 2014 at 10:51 AM, Tom Lane 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