![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| printing each users by processes | sam4now | Shell Programming and Scripting | 12 | 04-28-2008 06:11 PM |
| Processes and Users | barbus | Shell Programming and Scripting | 22 | 10-03-2007 07:09 PM |
| users and there processes | iago | UNIX for Dummies Questions & Answers | 3 | 09-10-2007 02:51 PM |
| i need a scipt to email users with idle processes!? | sheppy28 | Shell Programming and Scripting | 0 | 02-02-2007 04:08 PM |
| Displaying the processes of users | olimiles | Shell Programming and Scripting | 2 | 08-18-2006 02:57 PM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Users and processes
Hi All,
I am trying to write a script to list all users and their processes. I cant seem to find out how to link the PID to the user. For example if i run ps -a I get a nice list of all the processes running and their PID, but no information about which user is running them. If i use w i can see what the users are running but no reference to the PID, which i need. Basically I need to find PID, User, and tty. If i could link the PID to a user then i could simpley grep the PID lines from the ps -a return and get what I want, but I dont know how to find this info. Thanks, Chris. |
|
||||
|
shereenmotor: ps -ef doesnt output the username at all, it does however output the UID, which still doesnt help because I need to link the UID to a username.
grial: ps -O will work, but i dont know what format I would need for my question. |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|