PATCH for a more-POSIX `ps', and related adventures

Garance A Drosihn drosih at rpi.edu
Sat Mar 20 16:16:06 PST 2004


At 12:22 AM +0100 3/21/04, Dag-Erling Smørgrav wrote:
>
>>  The SUSv3 standard describes an option `-U userlist':
>>       Write information for processes whose real user ID numbers
>>       or login names are given in userlist
>>  We already have a `-u`, and I even use it, so I wasn't going to
>>  steal that!  However, I did want to have this ability, so I added
>>  it as -R.  I will assume this seems reasonable.
>
>What's the difference between the existing -U and the new -R?

"real user" vs "user".  Basically, whether or not you will see
setuid programs that the user has started up.  For instance,
right now on my system:

(22) ps -x -o pid,user,uid,ruid,tt,command -U scatters
   PID USER       UID  RUID  TT  COMMAND
   919 scatters   561   561  p1  /usr/local/bin/bash
  1098 scatters   561   561  p2  /usr/local/bin/bash

(23) ps -x -o pid,user,uid,ruid,tt,command -R scatters
   PID USER       UID  RUID  TT  COMMAND
   917 root         0   561  ??  screen
  1096 root         0   561  ??  screen
   919 scatters   561   561  p1  /usr/local/bin/bash
  1098 scatters   561   561  p2  /usr/local/bin/bash

-- 
Garance Alistair Drosehn            =   gad at gilead.netel.rpi.edu
Senior Systems Programmer           or  gad at freebsd.org
Rensselaer Polytechnic Institute    or  drosih at rpi.edu


More information about the freebsd-standards mailing list