They offer different flash templates with latest features.
Login

Forgot password
Register
Back
Written by:
stapiagutierrez
Score: 138
votes: 156
Format: Article

 How to close a program that has frozen.


Although Linux is a really stable platform, there will be some times that a program will freeze. In those cases most people are stuck on what to do. This little guide is for them.

Generally you have two choices for closing a stuck program:

1. Close all programs related to that program (including multiple windows of the program)

2. Close a program with your mouse cursor.

I'll explain both a bit.

 

Use the KillAll feature to kill a program.

1. Press Alt+F2 and type in gnome-terminal to open a terminal session.

2. Inside of the terminal type in sudo killall <application-name>. For example, to kill firefox type in sudo killall firefox.

 

Use the xkill feature to kill a program you click on

1. Press Alt+F2 and type in gnome-terminal to open a terminal session.

2. Inside of the terminal type in sudo xkill; then click on any window to kill it. This command makes your cursor act like a terminator, deadly.

 

That's all there is to it. Hopefully you never experience a crash.


Tags: frozen, xkill, stuck
Created: 4 years ago.
Last edited: 4 years ago.
Read 21034 times.

Comments
6 months ago

jfleen
Nice tip. Thanks.  
6 months ago

MW4SNIPER
had to actually open the window, thought i could click on the tab, doesnt work that way, for anyone else who is a inept at computers as me!  
8 months ago

Angelanna81
Clear description. Thanks :)  
10 months ago

jahid_0903014
awesome!  
1 year ago

DestinTheGreat
thx  
1 year ago

SharpSteve
sudo xkill command did the trick after package installer locked up. Thanks!  
1 year ago

sujitnag
nice  
1 year ago

jkumar
thanks a lot , It really helps  
2 years ago

azimifm
u can add a shortcut for it on keyboard shourtcuts in system setting. on the buttom of the window there is a plus sign click on it
name: xkill
command: xkill
then add a shortcut, you can use ctrl+x as in ubuntu or anything you like
 
2 years ago

fanf42000
thank you.  
2 years ago

revo
thank for your help!  
2 years ago

j_rueger
Please edit your post and clarify that most of the time, xkill does not require sudo, just Alt+F2, enter "xkill" and kill away...  
2 years ago

thanh4890
Very essential post, thank for your help!  
2 years ago

pavankm
very helpful particularly when the main ui crashed.  
2 years ago

davey1986
Thank you  
2 years ago

BARN
hey stapia........my whole system freezes as soon as i try to start my webcam by the combination 'Fn+F10' which works perfctly fine in windows.Any idea about how to survive this instead of shuting down the system
 
3 years ago

SonhadorPR
You should also show us -newbies- how to find the processes.  
3 years ago

kingugo
thanks. just killed a stubborn send to window with the sudo xkill command  
3 years ago

blueXrider
Good to know for the new user  
3 years ago

Steampunk-Nick
great tutorial!  
3 years ago

mysoomro
Thanks. It's a really helpful tutorial.
Unfortunately I face this problem. Even bigger than this problem. My entire Mint OS freezes. And when it freezes, nothing works. And it happens very often. Can you help me out with this?
One friend in forum suggested that it might be because of low RAM. But I have 1 GB RAM. I think it's enough to run the system smoothly.
 
3 years ago

Angtagapagligt
There is a much comfortable way for the common user. Put the "force quit"-Button in your taskbar. Than click on it when a application hangs. An than click with your cursor on a window of the application. Ready.  
3 years ago

dazw2000
Quality, as trying out all sorts of new stuff (BETA VERSIONS) now I can just close the window without the reset.  
3 years ago

ibrahimsuprapto
That a simple great tutorial, Love it ! Thx bro :D  
3 years ago

MintyFresco91
Its always nice to get more of a feel with the "F" keys. I can now say my mouse feels invincible, program terminated ;D.  
3 years ago

soulsclerosis
A handy trick, thanks a lot.  
3 years ago

Tonya
Many thanks to author and to all who proposed the alternative options.  
3 years ago

gvhools
hello from greece.
very good,but some times we have zombies!
 
3 years ago

Firoz_usf
Thanks A MILLION .  
3 years ago

Twix2247
thanks. I was wondering how to do this. I had my VLC player lock up for some reason once and just rebooted. This way is much simpler.  
3 years ago

darwinarya
wow ... good one :)
thx for sharing
 
3 years ago

jrwilson
Good to know. Thanks.  
3 years ago

jahwarrior4179
Being on a netbook, this will come in handy.  
3 years ago

Ruth_Mary
In my opinion the best way to kill a frozen app is with the applet (see alphazero user at the end of this comment list). But there is another way that I have not readen in any comment here: System Monitor.  
3 years ago

jxgreat
thankyou very muche very helpful.  
4 years ago

Boringbytes
Thank you
comments on this tutorial are almost as interesting as the tutorial itself.
 
4 years ago

merelyjim
Funny that Linux uses terminology that the end-user understands ['killing' a Window]. Since I usually have the CLI open on at least one workspace anyway... KillAll!  
4 years ago

grey1960envoy
very simple too bad the other guys (windoze) aren't this easy to figure out !!!  
4 years ago

morbidtourus
nice share... i like xkill method that u shared...  
4 years ago

Reves-Yosoy
Using the command '$ top' in a terminal will give us a list of all the processes running at the moment, to kill one, we just need to press 'k' in the keyboard and then, write the pid of the process (shown in the list we got) and press enter.
At least, I've done it this way with good results.
 
4 years ago

axelinux
I used to use ps aux | grep and then kill process by process  
4 years ago

Apehanger
Love xkill. Ensure window is visible before calling it up.  
4 years ago

elscripto
There is a third option suitable at cases, when the above pointed methods will not save you, simply because they are not applicable.

Sometimes, mostly at games, more specifically at Windows games played via Wine, the entire graphical screen freezes.
Ctrl-Alt-Del and Ctrl-Alt-Backspace are not options, as you want to kill only the faulty game/processes, and at the same time not to lose other running applications/processes.

The steps to kill the faulty process are:
1. Open another TTY console of your choice - Press one of Ctrl-Alt-F2 through Ctrl-Alt-F6 sequence;
2. Login at the console;
3. Navigate the processes by issuing the command: 'ps -ef | less' and find the frozen processes;
4. Escape from less and kill these processes with the command: kill pid1 pid2 ... pidN , substiting the correct values for the pids;
5. Switch and finally return to the original graphical screen by pressing Ctrl-Alt-F7.
Enjoy.
 
4 years ago

linXea
when something very bad happened to you, " kill -9 " is your friend. It will kill almost anything, succeed where "killall" fail.  
4 years ago

TheBigGeeUK
I'm new to Linux Mint, in fact although I've used a few different distro's I'd still say I'm a linux newbie.

Never knew about the this, thanks for the tutorial!
 
4 years ago

ander
There are also times when a full-screen game crashes your desktop's video and gives you a black display---and you can't kill it because you can't see anything.

That's when I've found Ctrl+Alt+Backspace useful. It ends your desktop session and returns you to the logon screen. Of course if you have any open documents, you'll lose any unsaved data. But it's better than hitting your power switch. ;?)
 
4 years ago

justin
Additionally, I recommend adding that sometimes killall does not work. At that point you need to break out ' kill -9 ' which will absolutely kill whatever you want, no questions asked.  
4 years ago

Darrel
Thanks, I'll go for the terminator next time, instead of a reboot.  
4 years ago

vipek
Nice. I didn't know about xkill :)  
4 years ago

srini2174
1. Click Ctrl + Alt + Esc
2. Click on the window which you need to kill.

This would kill the program that has frozen
 
4 years ago

alphazero
for additional of this tutorial :

we can use force quit applet that can be added in panel. Just click that applet, can click again which frozen application that want to be killed.
 

Other tutorials from stapiagutierrez