explain this command please
Please help me with this command..
How is it being used, what does it do... how is pipe being used here etc.. lsof | grep IPv | grep 3001 | awk '{print $2}' | xargs -l -i kill -9 {} |
well first it runs lsof (lists open files)
then it extracts from the lsof output only the likes with IPv in them then it extracts from those selected lines all the lines that contain 3001 then it uses these remaining lines are pattern scanned by awk, which extracts the second element from each line and pipes that to xargs xargs then sends all of that to the kill command, which terminates the pid extracted with a -9 as far as what does it do well i'm guessing much the same as fuser for instance: it determines what programs have certain resources open. In this case the resurces are IPv identified, and the 3001 (from shady memory of reading a book two weeks ago is a certain IPv6 address group, but i could be hella wrong about that). finally it takes the information of what programs have stuff open and terminates the associated program. Finally piping is used to filter out the resources we are interested in, then identify the program id and lastly kill it, so the pipes perpetuate data amongst programs |
Re: explain this command please
Quote:
that response? :P http://www.linuxquestions.org/questi...hreadid=340825 Cheers, Tink |
you're mean Tinkster =p
|
Quote:
stick to the rules and remain within the original thread he created? That aside that's none of your business ;) Cheers, Tink |
LOL ... yeah you are mean Tinkster
hee hee hee so did i get that right anyways ? I don't really know awk... |
I am sorry for that.. but I could not find that previous posting in the forum...
I am really sorry... |
You could, for instance, use the search
and entered your username in the "Search by user name" field. The search feature is actually very valuable ;) Cheers, Tink |
Quote:
tcp and udp (he didn't mention which it was). Cheers, Tink |
w00!
|
All times are GMT -5. The time now is 07:27 AM. |