Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Mar 2004 19:48:37 +1100
From:      Peter Jeremy <peterjeremy@optushome.com.au>
To:        Alexey Dokuchaev <danfe@nsu.ru>
Cc:        arch@freebsd.org
Subject:   Re: Adding `pgrep' and `pkill' to /usr/bin
Message-ID:  <20040325084837.GA57169@server.vk2pj.dyndns.org>
In-Reply-To: <20040325065314.GA64827@regency.nsu.ru>
References:  <p0602046cbc87c722e8bc@[128.113.24.47]> <Pine.BSF.4.21.0403241550160.63489-100000@InterJet.elischer.org> <20040325065314.GA64827@regency.nsu.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Mar 25, 2004 at 12:53:14PM +0600, Alexey Dokuchaev wrote:
>On Wed, Mar 24, 2004 at 03:51:22PM -0800, Julian Elischer wrote:
>> 
>> 
>> On Wed, 24 Mar 2004, Garance A Drosihn wrote:
>> >    The `pgrep' command searches the process table on the running system
>> > and prints the process IDs of all processes that match the criteria
>> > given on the command line.  Criteria includes matching against the
>> > process-name, or matching against the full-argument list of the
>> > processes.
>
>I've been using alias "psg = ps auxlww | grep" for pretty much the same
>purpose.  Is there some very strong reasoning behind bringing in some
>new facility?

grep'ing the output from ps generally requires tricks to avoid the grep
process matching.  pgrep avoids this and allows better control over what
is being matched.

At another level, Unices tend to differ most when it comes to
administration utilities.  This requires sysadmins to mentally change
gears as they move between xterm (should I type "ps -ef" or "ps -ax"
into this terminal?).  Adding (useful) sysadmin utilities from one of
the more common Unices would seem to be A Good Thing.

Peter



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040325084837.GA57169>