From owner-freebsd-stable@FreeBSD.ORG Mon Mar 31 21:11:59 2014 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 6B529F79 for ; Mon, 31 Mar 2014 21:11:59 +0000 (UTC) Received: from isis.morrow.me.uk (isis.morrow.me.uk [204.109.63.142]) by mx1.freebsd.org (Postfix) with ESMTP id 45FB07C3 for ; Mon, 31 Mar 2014 21:11:58 +0000 (UTC) Received: from anubis.morrow.me.uk (host86-173-254-150.range86-173.btcentralplus.com [86.173.254.150]) (Authenticated sender: mauzo) by isis.morrow.me.uk (Postfix) with ESMTPSA id C141F4508D for ; Mon, 31 Mar 2014 21:11:56 +0000 (UTC) DKIM-Filter: OpenDKIM Filter v2.8.3 isis.morrow.me.uk C141F4508D DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=morrow.me.uk; s=dkim201101; t=1396300318; bh=ZQAxtvtiq6k5aK/2EhrMQHg3tCkseTnrP8hioEQ4xeo=; h=Date:From:To:Subject:In-Reply-To; b=IVCspt+VGpzLN1SFqishr9gBf9hkDJSysCZFnMdBCfORPrwCsWqVxuAIMtD/Dks5a v8FyH/ExRA9UgWlZ9tpguUwUJCu0hw1KoUmQEb/IjuJTouKMxFIqLOIzTZmtZ/tf0T urlCA+b8LNt/Dq4K3YTj7XBMQgb3OvvjMiwJ7i/0= X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.98.1 at isis.morrow.me.uk Received: by anubis.morrow.me.uk (Postfix, from userid 5001) id 27AE21270B; Mon, 31 Mar 2014 22:11:52 +0100 (BST) Date: Mon, 31 Mar 2014 22:11:52 +0100 From: Ben Morrow To: freebsd-stable@freebsd.org Subject: Re: Process handlers, and zombies, or preap(1) Message-ID: <20140331211147.GA52184@anubis.morrow.me.uk> Mail-Followup-To: freebsd-stable@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <26dbb84bafaf0114cb75c3fbe060d412.authenticated@ultimatedns.net> X-Newsgroups: gmane.os.freebsd.stable User-Agent: Mutt/1.5.23 (2014-03-12) X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 31 Mar 2014 21:11:59 -0000 Quoth "Chris H" : > I'm evaluating/experimenting on releng_9. The install, and now > custom kernel have noting exotic, or anything out of the ordinary. > top(1), and ps(1) indicate a (1) zombie, or process. On > my releng_8 systems, when I occasionally encounter one of these, > they soon disappear (are reaped) from the process table. While I > have not investigated this far enough on both versions to determine > whether the parent process reaped the child on the releng_8 systems, > and the parent on releng_9 is simply an irresponsible parent, eg; > a different parent. What is the parent? > Before I do, I was wondering if there was any > specific difference between the 2 versions that might cause better > handling of such situations. While I recognize that resource > starvation is HIGHLY unlikely, except by perhaps a rouge parent A rouge parent? :) > spawning multitudes of zombies. I thought it might be useful for > "housekeeping" to 1) provide a process table housekeeper (zombie > reaper), That's called init(8). When the parent exits, init will wait for the zombie. > or 2) create a system utility/command like SunOS/OpenSolaris > has; preap(1). That seems like a bad idea, to me. Generally speaking I would expect it to be safer to kill and restart the parent, allowing init to do its job. Ben