Can someone describe where the ps console command in linux gets a list of processes? It seems like anytime I run ps, the only processes that come up are bash and ps itself. Are there other commands that would give me a better list of processes so that I can "task manage" (sorry to borrow a Windows term) from console? If it makes a difference, I'm using ubuntu 10.04 ---update--- Thanks for the answers, now I'm curious about the difference between these different ps commands. ps axwww seems the most comprehensive, but ps aux seems to give more useful data (CPU and mem usage)
|
migrated from stackoverflow.com Jul 23 '10 at 2:53
|
Try ps aux sometime. Or if you have kde installed, you could use ksysguard. Or gnome system monitor. |
|||
|
|
|
I don't know exactly where ps gets it's information. It might be from /proc/{procID}/status. For example
I mostly use |
|||
|
|
|
To manage processes instead of just displaying them have a look at top (installed by default on Ubuntu), atop or htop (both not installed by default on Ubuntu). Especially for top reading the man page is necessary for everything but the most basic usage. |
|||
|
|
|
I always prefer "ps fx" command but many variations can be put based on your requirement. Like "ps aux" , "ps efx" "ps -ely" |
|||
|
|
|
ps fetches the information from the proc filesystem ( What confuses you is the fact that, by default, ps seems to only show the current process and its childs. So it you run Use
And be sure to read |
|||
|
|
|
take a look at Hack 91. Ps Command Examples. |
|||
|
|