Here’s how to kill a hung process/program in Linux:
1. Issue the following command at the terminal to view a list of running processes –
Now, make a note of the PID for the process you want to kill. For example, we want to kill the ‘Firefox Browser’ which has got hung. The PID for firefox in the above scenario is 2124.
Press ‘Ctrl‘ + ‘C‘ keys to stop and come out of the top command.
2. Now issue the following command at the terminal –
sudo kill <PID of the process to be killed>
In our scenario, the command would be –
sudo kill 2124