From owner-freebsd-hackers@FreeBSD.ORG Sat Nov 7 20:27:39 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 33FCC106568B for ; Sat, 7 Nov 2009 20:27:39 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mx21.fluidhosting.com [204.14.89.4]) by mx1.freebsd.org (Postfix) with ESMTP id CFE638FC16 for ; Sat, 7 Nov 2009 20:27:38 +0000 (UTC) Received: (qmail 497 invoked by uid 399); 7 Nov 2009 20:27:37 -0000 Received: from localhost (HELO foreign.dougb.net) (dougb@dougbarton.us@127.0.0.1) by localhost with ESMTPAM; 7 Nov 2009 20:27:37 -0000 X-Originating-IP: 127.0.0.1 X-Sender: dougb@dougbarton.us Message-ID: <4AF5D840.6090707@FreeBSD.org> Date: Sat, 07 Nov 2009 12:27:44 -0800 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Thunderbird 2.0.0.23 (X11/20090822) MIME-Version: 1.0 To: Jilles Tjoelker References: <20091106222446.GB60707@stack.nl> <20091107112832.24b0c0d4@ernst.jennejohn.org> <20091107130136.GI2331@deviant.kiev.zoral.com.ua> <20091107201954.GA84099@stack.nl> In-Reply-To: <20091107201954.GA84099@stack.nl> X-Enigmail-Version: 0.96.0 OpenPGP: id=D5B2F0FB Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Kostik Belousov , freebsd-hackers@freebsd.org Subject: Re: [patch] add pwait utility X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Nov 2009 20:27:39 -0000 Jilles Tjoelker wrote: > On Sat, Nov 07, 2009 at 03:01:36PM +0200, Kostik Belousov wrote: >> On Sat, Nov 07, 2009 at 11:28:32AM +0100, Gary Jennejohn wrote: >>> On Fri, 6 Nov 2009 23:24:46 +0100 >>> Jilles Tjoelker wrote: > >>>> I propose adding a small new utility to /usr/bin: pwait. Similar to the >>>> Solaris utility of the same name, it waits for any process to terminate. > >>> Why not /bin so it can be used before /usr is mounted? I agree. It's such a tiny thing there's no reason not to put it in /bin, and the potential benefits (being able to use it when /usr is not present) far outweigh the costs. >> And it seems to make sense to add this functionality to pkill/pgrep >> binary, creating another hardlink to it. > > Hmm, pwait's syntax is incompatible: it takes pids (pkill says: use > kill) and the -v option does something totally different. I agree with Jilles, I don't see any reason to complicate this. If there is some reason that pkill/pgrep would need the functionality internally then the pwait stuff could be turned into a library, but I don't think that's what Kostik was proposing. When you get this committed (in whatever form) send a note to freebsd-rc@freebsd.org so that we can look at re-implementing wait_for_pids with this. I think this is a very nice addition, thanks for taking it on. Doug -- Improve the effectiveness of your Internet presence with a domain name makeover! http://SupersetSolutions.com/