Re: posix ps (was Re: Adding `pgrep' and `pkill' to /usr/bin)

From: Garance A Drosihn (drosih_at_rpi.edu)
Date: 03/27/04

  • Next message: Julian Elischer: "Re: posix ps (was Re: Adding `pgrep' and `pkill' to /usr/bin)"
    Date: Fri, 26 Mar 2004 19:13:45 -0500
    To: "Cyrille Lefevre" <cyrille.lefevre@laposte.net>, "David Schultz" <das@freebsd.org>
    
    

    At 6:40 PM +0100 3/26/04, Cyrille Lefevre wrote:
    >
    >two years ago, I've added posix syntax and so to my locally
    >ps(1). For instance, I'm currently adding the notion of
    >dynamic personalities (the term comes from linux) instead
    >of static #define such as... say :
    >
    >$ ps -X help
    > any bsd bsd43reno bsd44 default extended freebsd hpux
    > irix netbsd none openbsd pedantic posix relaxed solaris
    > sunos susv3 tru64
             ...etc...

    >When finished, I'll probably submit these changes as a port,
    >... since I suppose -arch will reject these important changes
    >to a native command.

    I (personally) think that is overkill for a base-system command.
    I do think that it is important for us to improve on what we
    have for `ps, but that does not mean we immediately have to
    rush out and re-implement every version of `ps' on the planet.

    You are suggesting that we go from being the least feature-full
    and most-oddball `ps', to trying to match every `ps' along with
    every subtle formatting-nuance of every system. With the changes
    that I just did, I went through a fair amount of trouble to make
    sure that I was not increasing the size of `ps'. There are some
    FreeBSD users who need to squeeze the OS onto very small file
    systems, and I think that is a reasonable thing for our users
    to want. I (personally) think that the size and complexity of
    some all-encompassing `ps' is not worth the effort, and not worth
    the PR's we will get over every feature does not *EXACTLY* match
    how it behaves on the "original OS".

    I can see your `ps' being a very good option to have as a port,
    and I might even install it in some situations, but I do not
    think we want something that elaborate for a base-system command.

    >here are some sample outputs :
    >
    >$ PERSONALITY=freebsd ps -?

    Secondly, I personally am not fond of commands which COMPLETELY
    change their behavior based on environment variables. Different
    options, different formats, different rules.

    If nothing else, writing the man page for that would be a real
    nightmare, and I am no good at writing man pages... :-)

      - - - - - - - - - - - - - - - - - - - - - - - - -
    HOWEVER,
    Note that in a different message, written
               on March 25/2004, Jacques A. Vidrine wrote:
    >On Mon, Mar 22, 2004, Garance A Drosihn wrote:
    > > Great. So what should I do here?
    >
    >I dunno. Add a completely POSIX compliant ps command into
    >/usr/posix ? Or replace /usr/bin/ps with a completely POSIX
    >compliant ps and move our traditional one to /usr/ucb? :-)
    >
    >Seriously, we should give some hard thought into how to
    >provide/migrate to a POSIX compatible utilities environment.
    >It's been discussed on the lists before, but I still believe
    >providing POSIX compatible versions of utilities on a separate
    >path is the only clean way to make this happen.

    I do have some ideas of what I want to do to provide FreeBSD
    users with at least an option for posix behavior out of `ps'.

    I was going to write those up in reply to this message, but I
    have a steady-stream of "emergency interruptions" (here at work)
    today, and I'm supposed to be somewhere else right now, so I
    guess my thoughts will wait until a later date.

    The one thing I would say is that I expect to do a few gradual
    updates which will get us "somewhat better". I do not expect
    to write one cure-all update that attempts to solve everything
    at once. That is just not the way I like to work.

    -- 
    Garance Alistair Drosehn            =   gad@gilead.netel.rpi.edu
    Senior Systems Programmer           or  gad@freebsd.org
    Rensselaer Polytechnic Institute    or  drosih@rpi.edu
    _______________________________________________
    freebsd-arch@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-arch
    To unsubscribe, send any mail to "freebsd-arch-unsubscribe@freebsd.org"
    

  • Next message: Julian Elischer: "Re: posix ps (was Re: Adding `pgrep' and `pkill' to /usr/bin)"

    Relevant Pages

    • Re: Tool zum Festplatte =?ISO-8859-1?Q?l=F6schen_=28wipe=29=3F?=
      ... | "How to use Device Files for tar? ... | There is no need to create a POSIX /dev directory as it is simulated ... These devices cannot be seen with the command ls /dev ... Die vollständige Liste der Cygwin-Devices findet man zur Not im ...
      (de.comp.hardware.laufwerke.festplatten)
    • Re: sed help
      ... is the standard syntax. ... The braces can be preceded or ... you'd have to use the solution I gave to be POSIX. ... Anyway, for me, the idea was that "}" is a sed command, so must ...
      (comp.unix.shell)
    • Re: type builtin in posix-only shell
      ... Yes, type is POSIX, that's probably a bug in posh or in your ... You can also try command -v cmd. ... But "command -v" is required by XSI (Unix if I understand ... | extensions marked with the XSI extension marking (see ...
      (comp.unix.shell)
    • Re: Great SWT Program
      ... specified in POSIX, particularly, that a command line of the form ... "binaryname arguments" launches a new, ... And of course "screen" is not a shell builtin, ...
      (comp.lang.java.programmer)
    • Re: showme date differenet from date posix output
      ... showme date differenet from 'date' posix output ... Try using the SHOWCLOCK command and see if it is different from the Posix ... To join/leave the list, search archives, change list settings, * ...
      (comp.sys.hp.mpe)