RSS
 

Archive for the ‘Mac’ Category

Kill a process in Mac OS X from the terminal command line

14 Oct

It can sometimes be necessary to kill a process in Mac OSX. We’ve all tried it.
To kill a process or program in the Mac OSX Leopard / Snow leopard / Lion do the following commands

ps -A | grep [name of program you want to close]

This will give you the number of the processes found (if any). Now just close them with this command

kill -9 [process id]

So, for example to kill my activity monitor program

ps -A | grep activity
39049 ??         0:01.81 /Applications/Utilities/Activity Monitor.app/Contents/MacOS/activitymonitord
kill -9 39049
 
No Comments

Posted in Mac