From owner-cvs-src Fri Mar 14 13:51:22 2003 Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 438F637B401 for ; Fri, 14 Mar 2003 13:51:20 -0800 (PST) Received: from mail.speakeasy.net (mail11.speakeasy.net [216.254.0.211]) by mx1.FreeBSD.org (Postfix) with ESMTP id 7F2AE43FDD for ; Fri, 14 Mar 2003 13:51:16 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 12295 invoked from network); 14 Mar 2003 21:51:24 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) by mail11.speakeasy.net (qmail-ldap-1.03) with DES-CBC3-SHA encrypted SMTP for ; 14 Mar 2003 21:51:24 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.8/8.12.8) with ESMTP id h2ELpDOv058107; Fri, 14 Mar 2003 16:51:13 -0500 (EST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.2 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: Date: Fri, 14 Mar 2003 16:51:31 -0500 (EST) From: John Baldwin To: Garance A Drosihn Subject: Re: cvs commit: src/sys/vm ... SIGDANGER Cc: "Daniel C. Sobral" , Mike Silbersack , Poul-Henning Kamp , Juli Mallett , Eivind Eklund , David Schultz , src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org, Pawel Jakub Dawidek Sender: owner-cvs-src@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On 14-Mar-2003 Garance A Drosihn wrote: > At 4:05 PM -0500 3/14/03, John Baldwin wrote: >>On 14-Mar-2003 Pawel Jakub Dawidek wrote: >> > >>> Why not choose process to kill by their priority? >>> >> > If we got some important processes even without uid=0 we could >> > renice them to value less than 0. >> >>I don't think raw priority should be taken into account, but using >>the nice value in the algorithm (perhaps as a weight of some sort?) >>sounds like a good idea actually. nice is an existent mechanism >>for SA's to mark which processes are more important than others so >>it seems intuitive to seek to preserve nice -20 processes at the >>expense of nice +20 processes. > > The problem is, 'nice' already has one specific meaning, and that > meaning is *not* "Sure, go ahead and kill me!". I feel uneasy > if we try to guess at which process to kill based on values which > are set for unrelated and perfectly-good reasons. [I do kind-of > like the idea of preserving processes with negative nice values, > but I would not want to assign any special kill-meaning to nice > values >= 0] Here when we nice a process, we use it to mark proceses that are important. If the OOM had to kill someone, the processes with negative nice would be the last ones we would like to see killed. Also, I didn't say that we couldn't do SIGDANGER in addition. IMO, using nice would be orthogonal to SIGDANGER. It would simply be a part of the algo of who to choose to send the final SIGKILL's to. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-src" in the body of the message