There are multiple ways to do it.
I will post the most common CLI methods.
You can use
killto terminate a process that is being run by you, or if logged in as root or using sudo you can kill a program run by anybody.
killhas many uses but I will only post the most simple one.
To kill a process using
killyou must first have its PID (process ID).
To get this you can use the command
You may then
bash$ pidof [process]
then you can
bash$ kill [output]
which will end process
bash$ pidof rhythmbox
bash$ kill 2531
would be used to kill rhythmbox
This is a rather long method however.
This is where the comand
You do not need to use the PID when using
You can simply use:
bash$ killall [process]
and the process will be killed.
bash$ killall rhythmbox
There is another option which lets you see if a program is misbehaving and kill it called
When in a shell simply type:
You get a CLI task manager which shows PID's and cpu usage etc.
gives me this:
You can kill a process by pressing 'k' then typing in the PID listed for it.
PID to kill: 2531
it will ask you:
Kill PID 2531 with signal :
and you can simply press enter to kill it or ^C (ctrl+C) to exit the program.