Identifying a running process
tony.arnold at manchester.ac.uk
Thu Jun 18 14:38:20 UTC 2009
> I want to learn how to identify and then stop a process - for example
> today I tried to restart a program that had just crashed and Ubuntu gave
> me a message along the lines of "XYZ is still running but not
> responding. Stop the process or reboot before trying again" or words to
> that effect.
> Rebooting was highly undesirable because it meant shutting down other
> programs. Too bad!
> Can someone help save the search and point me to some appropriate
> reading matter?
I use pgrep and pkill on the command line for this.
You can say pgrep XYZ and it will tell you the process ID of any process
whose name matches XYZ. Check the man page for more options.
You can also say pkill XYZ which will kill any process whose name
matches XYZ. Again, check the man page.
Tony Arnold, Tel: +44 (0) 161 275 6093
Head of IT Security, Fax: +44 (0) 870 136 1004
University of Manchester, Mob: +44 (0) 773 330 0039
Manchester M13 9PL. Email: tony.arnold at manchester.ac.uk
More information about the ubuntu-users