13

On Ubuntu 12.04 the default Movie Player has hanged on a frame while playing a (faulty?) mkv video. I tried to close it by right click > close but could not terminate it. It also does not start when I try to play a new video.

How can I kill the process from command line?

1
  • 5
    'xkill' in command line works for me well enough. After executing command, cursor turns into an 'X', then click the window for the Movie Player instance you want to kill.
    – Dodgie
    Dec 14, 2014 at 4:13

3 Answers 3

22

You should be able to use:

pkill totem

A generally helpful thing to find which processes are hogging the CPU is top: top screenshot then you can press k and type in the PID of the process, and then press Enter twice to kill it;

Another program that can do this is htop: htop screenshot This can also system resources being used, and processes can be killed by selecting them, pressing k, and then pressing Enter. Parent processes can also be found by pressing t to toggle tree view.

1
  • bash: kill: totem: arguments must be process or job IDs. But pkill worked. please edit your answer and I'll accept it. Thanks
    – wbad
    Dec 30, 2013 at 20:13
6

Easiest method:

killall totem

As is says: this will kill -all- instances named totem.

Alternative:

ps -ef |grep totem
rinzwind  3601  2236 14 21:05 ?        00:00:00 totem

and then kill the process

kill -9 3601

If totem is started as another user you will need sudo.

3

You can also use pstree -ps command to get a complete (tree-)list of running processes with sub-processes, like this:

    ├─mission-control(1689)  
    ├─modem-manager(912)  
    ├─mpd(1908)─┬─{mpd}(1909)  
    │           ├─{mpd}(1910)  
    │           ├─{mpd}(1911)  
    │           ├─{mpd}(1912)  
    │           └─{mpd}(1913)  
    ├─nmbd(1858)  
    ├─obex-data-serve(1652)

Then use terminals' search function cmd+shift+f to seek out the process in question, for instance; mpd followed by this command:

kill -9 1908

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .