From owner-freebsd-hackers@freebsd.org Wed Jan 27 12:07:36 2016 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF7A2A6F782 for ; Wed, 27 Jan 2016 12:07:36 +0000 (UTC) (envelope-from mailinglists@toco-domains.de) Received: from toco-domains.de (mail.toco-domains.de [176.9.39.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 9913F1EC7; Wed, 27 Jan 2016 12:07:36 +0000 (UTC) (envelope-from mailinglists@toco-domains.de) Received: from [0.0.0.0] (mail.toco-domains.de [IPv6:2a01:4f8:150:50a5::6]) by toco-domains.de (Postfix) with ESMTPA id 6E09C1B22068; Wed, 27 Jan 2016 13:07:28 +0100 (CET) Subject: Re: syslogd(8) with OOM Killer protection To: Pavel Timofeev , Baptiste Daroussin References: <56A86D91.3040709@freebsd.org> <20160127072850.GG35911@ivaldir.etoilebsd.net> Cc: freebsd-hackers@freebsd.org, Allan Jude From: Torsten Zuehlsdorff Message-ID: <56A8B300.5080503@toco-domains.de> Date: Wed, 27 Jan 2016 13:07:28 +0100 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 12:07:36 -0000 On 27.01.2016 09:27, Pavel Timofeev wrote: > 2016-01-27 10:28 GMT+03:00 Baptiste Daroussin : >> On Wed, Jan 27, 2016 at 02:11:13AM -0500, Allan Jude wrote: >>> On 2016-01-27 01:21, Marcelo Araujo wrote: >>>> Hi guys, >>>> >>>> I would like to know your opinion about this REVIEW[1]. >>>> The basic idea is protect by default the syslogd(8) against been killed by >>>> OOM with an option to disable the protection. >>>> >>>> Some people like the idea, other people would prefer something more global >>>> where we can protect any daemon by the discretion of our choice. >>>> >>>> Thoughts? >>>> >>>> >>>> [1] https://reviews.freebsd.org/D4973 >>>> >>>> >>>> Best, >>>> >>> >>> I do like the idea of generalizing it, say via rc.subr >>> >>> So you can just do: >>> >>> someapp_protect=YES (and maybe syslogd has this enabled by default in >>> /etc/defaults/rc.conf) and it prefixes the start command with protect -i. >>> >> I do support that idea, I think it is will be useful to more people. >> >> Bapt > > I'm one that people. I find this generilized way very usefull. > I have least a couple of daemons that it'd never wanted to be OOMed on > my machines. Besides syslogd, I'd protect sshd and even crond in some > cases. I would like a generalized way too. The first i thought to protect is my database. I never want to get it killed. Greetings, Torsten