[aklug] Re: Portability question

From: <bryanm@acsalaska.net>
Date: Wed May 20 2009 - 23:29:00 AKDT

On Wed, May 20, 2009 6:20 pm, Royce Williams wrote:
> Christopher Howard wrote, on 5/20/2009 5:34 PM:
>> Hi. Is the command "ps -e u" available on all *nix systems? (I.e.,
>> POSIX-compliant systems.) And does it generate the same output as in Linux?
>>
>> Even if you could just speak for your personal non-Linux OS, that would
>> be helpful.
>
> Depends on how portable you need it to be. :-)
>
> royce@heffalump$ uname -nr
> heffalump.prv.tycho.org 7.2-RELEASE
>
> royce@heffalump$ ps -eu
> ps: Process environment requires procfs(5)
> USER PID %CPU %MEM VSZ RSS TT STAT STARTED TIME COMMAND
> royce 4345 0.0 0.4 3380 1892 p0 Ss 6:19PM 0:00.02 -bash (bash)
> royce 4365 0.0 0.2 3280 912 p0 R+ 6:19PM 0:00.00 ps -eu

Note that Christopher put a space in the middle: "ps -e u".

Slackware Linux uses procps, which takes options of three
different kinds: single, double, and no dash. I'd be surprised
if there was much portability across different OSes.

--
Bryan Medsker
bryanm@acsalaska.net
---------
To unsubscribe, send email to <aklug-request@aklug.org>
with 'unsubscribe' in the message body.
Received on Wed May 20 23:29:10 2009

This archive was generated by hypermail 2.1.8 : Wed May 20 2009 - 23:29:10 AKDT