This is a discussion on AWK within the Shell scripting forums, part of the Development/Scripting category; PLZ HELP "ps -el" command list all the processess of all the terminals or of all the users workin...on terminals... ...
|
|||||||
| Register | FAQ | Members List | Calendar | Forgotten your password? | Mark Forums Read |
|
|||
|
PLZ HELP
"ps -el" command list all the processess of all the terminals or of all the users workin...on terminals... I want to develope an "awk" program or "awk command" on shell to summarise from the list of all processes, a count of processes run by every user including root. |
| Sponsored Links | ||
|
|
|
|||
|
but wc -l will just count the total nober of lines in the process...
how will it going to summerise man... i want a summery of few columns...and then the shud be according to sorted terminal wise or user wise. |
|
||||
|
I am not sure what you want you need to explain it little more
You can print out column stuff something as follows Code:
ps -el | awk '{ print $14}'
Code:
ps -el | awk '{ print $14}' | uniq | wc -l
|
|
|||
|
yes..the way u hv written the first example...
Code: ps -el | awk '{ print $14}' this...this is wht i want... now il'll take few columns like these...but nw i want to to arrange them according to terminal wise.... like first list columns of terminal tty1 then tty2 and so on till tty7... this is wht i want..nw may be u cn help me nw. |