Monday, June 7, 2010

Kill All Chrome Instance at once (Linux+ Windows)

Windows users can follow this instructions here.
Or simply use command




        taskkill /F /IM chrome.exe



Linux geeks can use this command 


    kill -9 `ps -A |grep chrome| cut -d "?" -f1`


How This works?
I am sure that, most of the Linux users can easily figure it out, but for those who want explanation here you go...
Command
  ps -A          list all the processes
  grep chorme     will filter only those process which has name as chrome
  cut -d "?"     will cut the process Id potion of the out put.
and
  kill -9   kills a process ,
so above command will kill all the process with name chrome.
Please Note that this command will work on those processes which are not command line (mostly launched from UI ) (i.e whose tty field is "?")

No comments:

Post a Comment