/ lots

Chat 6168 by Anonymous on 07/01/2011

<Balatro> Electroly: It died on me once and wouldn't restart. I had to ps -aux or whatever the fuck it is and kill the process. Then it started fine.
<Electroly> ah, nothing good old `ps aux l grep Proteus l awk '{print $2 }' l xargs kill -9` won't fix.
<Electroly> much better, that worked.
  * Gandalf stares at Electroly
<Gandalf> And I thought I was a Unix dork.
<Balatro> Yeah, it was so much less effort to do that then to type a command, quickly see the process and kill it by PID :)
<Electroly> you are a unix dork
<Electroly> Balatro: there were like 10 Proteus processes, dude.
<Balatro> Funny, I had 1 ;)
<Electroly> dunno where these all came from, but i killed them all.
<Electroly> now all is well
<Gandalf> Electroly: I understand ps, grep, and xargs. Explain how that awk thinger works, though? :)
<Electroly> Gandalf: awk is pretty simple.  it treats the stdin as a bunch of columns
<Electroly> and lets you reformat the output.  { print $n } is typical, where n is the column number to print out.
<kurros> AWK AWK MOTHER FUCKER
<Electroly> it uses whitespace as the column delimiter by default, but you can change that by some argument to it
<Gandalf> ah, and in ps aux the PID is the second column, thus $2, right?
<Electroly> yup
<Electroly> you can do other stuff with awk, like awk '{ print "Whee!  The PID for " $10 " is " $2 "!" }'
<Balatro> It makes me hot when you talk unix.
<Electroly> rm -rf /home/Balatro
<Balatro> That's /homo/Balatro, honey :)
   Comments (0) Topics:

    Similar:

    Chat 16669BigPigPeaches: So my GF and I are watching "The Empire Strikes Back" last night. Let me say that this is possibly my favorite movi...
    Chat 4840cameltoe: Best resignation letter ever: ...
    Chat 21296Omi: My brother thought it'd be funny to take keys from my keyboard and put them around the house ...
    Chat 2875nick: FUCKING HELL!!!! .. nick: I swear one day I'm just gonna go and hunt down every stupid bitch on earth and put them out of their...
    Chat 22721FireSlash: So, at my office they're deploying a bunch of new HP Color Laser printers. These things are hot. Double sided printing, fast...
    Chat 10369Shovel: I ran across the worst named person in the world today... ...
    Chat 17696Galactic: you know what's ALWAYS bothered me? cold cereal mascots ...
    Chat 13100Psy: how many MB in a Gig again? .. seafoodgod: 1024 ...
    Chat 1838y2kThug: i worked with a pretty dumb old broad when I was in Stoneham ...

    Recent Searches:

    Help us Spread the Word: