From owner-freebsd-hackers Tue Sep 10 01:42:14 1996 Return-Path: owner-hackers Received: (from root@localhost) by freefall.freebsd.org (8.7.5/8.7.3) id BAA01047 for hackers-outgoing; Tue, 10 Sep 1996 01:42:14 -0700 (PDT) Received: from ns.pa-consulting.com (ns.pa-consulting.com [193.118.224.1]) by freefall.freebsd.org (8.7.5/8.7.3) with SMTP id BAA01042 for ; Tue, 10 Sep 1996 01:42:09 -0700 (PDT) Received: from SMTPGATE.PA-CONSULTING.COM by ns.pa-consulting.com (8.6.4) id JAA00457; Tue, 10 Sep 1996 09:52:05 +0100 Received: by SMTPGATE.PA-CONSULTING.COM with Microsoft Mail id <32359D17@SMTPGATE.PA-CONSULTING.COM>; Tue, 10 Sep 96 09:53:43 PDT From: Duncan Barclay To: freebsd-hackers Subject: undocumented kernel priority changing Date: Tue, 10 Sep 96 09:41:00 PDT Message-ID: <32359D17@SMTPGATE.PA-CONSULTING.COM> Encoding: 36 TEXT X-Mailer: Microsoft Mail V3.0 Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Hi Does anyone know why the following is not documented (either in the nice, renice, or getrlimit pages, and not in the 4.4 "daemon" book) in kern_synch.c (2.1.0R, havent had time to put on 2.1.5R) mi_switch() ... /* * Check if the process exceeds its cpu resource allocation. * If over max, kill it. In any case, if it has run for more * than 10 minutes, reduce priority to give others a chance. */ ... if (s > 10 * 60 && p->p_ucred->cr_uid && p->p_nice == NZERO) { p->p_nice = NZERO + 4; resetpriority(p); } ... It took me a while to figure out what was nicing my processes (would you believe it, one was an editor!). Whilst I acknowledge that a lot of people wont see this happening it is rather annoying to have it and it being not documented (unlesws I missed it). Shoot me if you will but a couple of config options may not go amiss, at least for single/few user sites. I will plonk them in sometime soon. Cheers Duncan Barclay