Did you know LQ has a Linux Hardware Compatibility List?
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 09-09-2005, 03:08 AM   #1
LQ Newbie
Registered: Jul 2002
Posts: 27

Rep: Reputation: 15
How to determine who the process' owner* is?


I am currently working on the set guid property and I am not able to determine who the process' owner* of a given process is.

Neither the kde console guard nor the ps command seems to give any indication on who the process' owner* is.

My question is as follows: what is the command that allows to determine who the owner* of a given process is?


*(according to documentation below.)

I quote LPI Linux Certification In A Nutshell (O'Reilly): "Normally the user who launches a program owns the resulting process. However, if an executable file has its SUID bit set, the file's owner owns the resulting process, no matter who launched it."
Old 09-09-2005, 03:17 AM   #2
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971Reputation: 1971
just use the "u" flag with ps
1 members found this post helpful.
Old 09-09-2005, 03:23 AM   #3
LQ Newbie
Registered: Sep 2005
Distribution: Suse 9.2 64-bit
Posts: 5

Rep: Reputation: 1

Use "ps u"

gary 6753 0.3 0.4 9952 2272 pts/2 Ss 11:20 0:00 /bin/bash
gary 6761 0.0 0.1 3472 736 pts/2 R+ 11:20 0:00 ps u

or "ps aux" to get all the processes on the system. You can also use grep to find the process you want. So if you have started process called "job123" you would type "ps aux | grep job123"

I hope that helps.
1 members found this post helpful.
Old 04-20-2013, 05:40 AM   #4
LQ Newbie
Registered: Apr 2013
Posts: 1

Rep: Reputation: Disabled
stat -c %U $0


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
shell script to read ps -e output and determine process double processes. dr_zayus69 Programming 1 09-21-2005 05:37 PM
Determine process memory consumption ? shayer009 Linux - General 1 10-28-2004 02:03 PM
Owner KennieNL Linux - Newbie 2 07-16-2004 03:20 AM
How to determine whether a PROCESS is running, by a SHELL program? yuzuohong Linux - General 4 01-21-2003 08:41 PM
apache, process owner, and rsync/ssh question Kruel Linux - Networking 0 03-01-2002 12:25 PM

All times are GMT -5. The time now is 05:09 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration