How to handle system freezes on SolydX

New to SolydXK? This is the place to start.
Please check the other subforums to see if there's a more suitable place for your question.
User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

How to handle system freezes on SolydX

Postby ilu » 14 Mar 2015 13:27

As the title says: Firefox (or one of its addons) seems to have problem with some websites. I don't care much, that happens. But as a result the whole system freezes? Mouse still moves but I can't start htop because the desktop doesn't react anymore. Only thing I can do is a hard reboot. This is annoying to say the least. There must be a secret switch I don't know about - isn't Linux the OS that never hangs up?

Ctrl+Alt+Del brings up the screen saver, Ctrl+Alt+* should kill the front process but didn't work - maybe I took the wrong asterix (the numerical one or the alphabetical one - and if it's the last - with shift pressed?). The firefox window also seemed to loose focus when the freeze occurred.

Another internet post recommended to "Raise The Elephant" with commands like Alt+SysRq+something. What key is SysRq? And which of those should I take? They all sound scary.
Alt+SysRq+R switch keyboard to 'raw' mode
Alt+SysRq+E send SIGTERM (termination) signal to all processes except mother init
Alt+SysRq+I send SIGKILL signal to all processes, a little more aggressive
Alt+SysRq+S sync all filesystems to prevent data loss
Alt+SysRq+U remount filesytems as read-only
Alt+SysRq+B forcefully reboot

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: Firefox problem freezes SolydX

Postby Zill » 14 Mar 2015 13:47

ilu wrote:...There must be a secret switch I don't know about - isn't Linux the OS that never hangs up?
Linux is a kernel, not a complete OS and, as such, it very rarely hangs up! An OS is made up of a kernel plus very many other programs which generate processes that can, and sometimes do, get stuck and cause hang ups. While it is often possible to track down these errant programs or processes, the easiest solution is usually to shutdown the system cleanly and then restart.

This is where the "elephants" come in and I like to remember this with the acroynym "Raising Skinny Elephants Is Utterly Boring".

This simply means you hold down both the Alt key and the SysRq key (which is also often marked Prt Scr) and then hit each of the following keys in sequence: R S E I U B, leaving a few seconds between each keystroke to allow the system to respond. The final keystroke should trigger the reboot process and the PC should then restart without any errors.

Regarding your Firefox problem, I suggest you remove all your addons and then try adding them one at a time until you identify the guilty addon - then don't use it!

User avatar
fleabus
Posts: 1227
Joined: 16 Sep 2013 04:24
Location: Winchester, VA USA

Re: Firefox problem freezes SolydX

Postby fleabus » 14 Mar 2015 14:18

This can be a real problem on some laptops, as it requires three hands! :lol:

On my HP, by the time I'm holding [alt + (fn+sysrq)] All available hands are in use, and my fingers can't reach the other keys. So I need to call a buddy over to press R-E-I-S-U-B...

Doc, do I really gotta hold all these keys?? :D

So for me, on this machine, it's the ol' hard reset. <sigh..>

User avatar
bas_otten
Posts: 214
Joined: 19 Oct 2013 12:22
Location: Netherlands

Re: Firefox problem freezes SolydX

Postby bas_otten » 14 Mar 2015 18:45

Just an alternative idea:

From another computer start an ssh-session, or use a smartphone with JuiceSSH or something. Then log in remotely into the 'hanging' computer - assuming the ssh-daemon is still running. Issue 'ps -ef', identify the hanging firefox/plugin processes and kill them, if necessary kill -9. This way you might 'raise the elephant'. I tested this for a simple scenario of killing a single non-hanging application remotely.

User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

Re: Firefox problem freezes SolydX

Postby ilu » 14 Mar 2015 20:12

Aha, you have to raise all the elephants, one after the other. I will try that on the next opportunity.
SysRq key (which is also often marked Prt Scr)
I have one that is named "print s-abf" (don't ask, no idea what that means) - it's above INS and DEL. And the left "Alt" key? Having three hands would definitedly be preferable.

What about trying Ctrl+Alt+Asterix first? Which asterix? The numerical or the one you reach by pressing shift-+ ?

Regarding Firefox: I think RequestPolicy is the culprit but I want to keep it anyway for privacy reasons.

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: Firefox problem freezes SolydX

Postby Zill » 14 Mar 2015 20:35

bas_otten wrote:...From another computer start an ssh-session, or use a smartphone with JuiceSSH or something. Then log in remotely into the 'hanging' computer - assuming the ssh-daemon is still running. Issue 'ps -ef', identify the hanging firefox/plugin processes and kill them, if necessary kill -9.
This is a good idea but, IIRC, only the ssh client is installed by default, not the ssh server. This is easily rectified with a quick command:

Code: Select all

sudo apt-get install openssh-server
Note that the user should, as with all server packages, be aware of the additional security risks associated with running any server but IMO, these should be minimal for a typical SOHO installation running behind a NAT firewall.

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: Firefox problem freezes SolydX

Postby Zill » 14 Mar 2015 20:42

ilu wrote:I have one that is named "print s-abf" (don't ask, no idea what that means) - it's above INS and DEL. And the left "Alt" key?
Sounds about right. I always try to use the left "Alt" key for things like this as the right one can sometimes give strange results!
ilu wrote:Having three hands would definitedly be preferable.
It's even harder for Zill with only a sink plunger for an arm... :-)

User avatar
bas_otten
Posts: 214
Joined: 19 Oct 2013 12:22
Location: Netherlands

Re: Firefox problem freezes SolydX

Postby bas_otten » 14 Mar 2015 21:29

Zill wrote:IIRC, only the ssh client is installed by default, not the ssh server
I use SolydK64 and there I'm sure openssh-server is installed and running by default. Just try 'ssh localhost' and see.
If installing openssh-server would need to be done first, then my 'idea' is less likely to be chosen for this problem.

kurotsugi
Posts: 2260
Joined: 09 Jan 2014 00:17

Re: Firefox problem freezes SolydX

Postby kurotsugi » 14 Mar 2015 22:25

Firefox (or one of its addons) seems to have problem with some websites. I don't care much, that happens. But as a result the whole system freezes? Mouse still moves but I can't start htop because the desktop doesn't react anymore.
press ctrl+alt+f1 to get a console then kill firefox with pkill command. you can press ctrl+alt+f7 to get back into your desktop. else, as precaution, you can register xkill on a combo button. whenever an app hang you can execute that combo button and click the window to kill that app. if you could launch terminal (usually ctrl+alt+t will bring one) you can also execute xkill from there.
Ctrl+Alt+Del brings up the screen saver, Ctrl+Alt+* should kill the front process but didn't work
not every DE have same combo button. you need to check whether if the combo button is registered/activated. if the combo button is activated, the first combo will log out the system while the second combo does nothing unless you register something under the command. if you want to kill firefox you can register xkill command on that combo button.
Alt+SysRq+something. What key is SysRq? And which of those should I take? They all sound scary.
sysrq is print screen button. the R-E-I-S-U-B combo should be executed one by one with some delay between them. press alt+sysrq+R, wait 3-5 seconds, press alt+sysrq+E, wait 3-5 seconds, press alt+sysrq+I, wait 5-10 seconds, .... normally after the third command your system will restarted in several seconds. if your system is not restarted you can continue with S-U-B command.

since the system is still works (i.e: the cursor is still moving) it means that hard reboot is actually not needed. you actually need to kill firefox either by xkill, pkill, or allkill command. in most cases, only firefox is frozen so you can call terminal either by ctrl+alt+t or using the start menu/shortcut. if you can't access the menu (all the desktop except the cursor is frozen) you can use a console with ctrl+alt+f1 as explained above.

User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

Re: Firefox problem freezes SolydX

Postby ilu » 15 Mar 2015 01:23

press ctrl+alt+f1 to get a console then kill firefox with pkill command ... register xkill on a combo button. whenever an app hang you can execute that combo button and click the window to kill that app. if you could launch terminal (usually ctrl+alt+t will bring one) you can also execute xkill from there.
Thank you, I will look into that register combo idea, sounds convenient. And yes, only FF hangs but the desktop is frozen too. Keyboard works.

Code: Select all

~$ ssh localhost
ssh: connect to host localhost port 22: Connection refused
I hope that means ssh-server is not running. I don't think I feel comfortable with it.

kurotsugi
Posts: 2260
Joined: 09 Jan 2014 00:17

Re: Firefox problem freezes SolydX

Postby kurotsugi » 15 Mar 2015 04:48

ssh is not needed because you can directly acces your system using one of six emergency consoles (ctrl+alt+F1 to ctrl+alt+F6). if you utilize all of them you can have up to 4 separated desktop on tty2,tty4,tty6,and tty7.

User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

Re: Firefox problem freezes SolydX

Postby ilu » 23 Apr 2015 17:53

I'm picking up this old topic because I'm running into the same problem again. This time it's a wine application thats freezes the desktop. I did alt-ctrl-f1 and used top and kill to close the wine application. Immediately the black terminal screen turned into scrambled graphics (from the wine app) and nothing worked anymore. No terminal either, no reaction to alt-ctrl-anything. Off course I had forgotten about the elefants :-( but I don't think the keyboard worked anymore. So I pressed the off button. System rebooted without a problem afterwards - can I be sure I did not destroy anything or do I have to do any additional checks?
Would it have been better to kill wine itself instead of the app?

User avatar
Arjen Balfoort
Site Admin
Posts: 9422
Joined: 26 Jan 2013 19:36
Location: Netherlands
Contact:

Re: Firefox problem freezes SolydX

Postby Arjen Balfoort » 24 Apr 2015 07:50

Please post this in a separate topic: although it's about a system freeze, the cause is entirely different.


SolydXK needs you!
Development | Testing | Translations

User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

Re: Firefox problem freezes SolydX

Postby ilu » 24 Apr 2015 14:04

I did not ask about the cause. Things like that happen and I have some ideas why (a problematic firefox addon which I want to keep anyway and too much strain on my graphics card which can't be helped except by buying a new one). I'm sorry my original thread title was misleading and I changed it.

I'm just asking general questions about how to handle system freezes.

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: Firefox problem freezes SolydX

Postby Zill » 24 Apr 2015 14:45

ilu: As freezes really should not happen very often, I guess a lot of your problems may well be due to demanding too much from your graphics card.

This thread gives good advice on handling system freezes and so I don't know what else you want. The only other tips I can think of that may be of use are:
  1. Hit Alt-F2 to bring up a dialog box. Then type "xkill" into the box and hit enter. Cursor should change to a "skull & crossbones" so move this to the errant application and left-click to kill the application. (or simply right-click to cancel this operation and return to a normal cursor).
  2. Hit Ctrl-Alt-Backspace to kill the xserver and end the session. This should kill all open applications and take you straight back to the login screen.
p.s. Don't forget that you can always raise the skinny elephants even if it is utterly boring (RSEIUB). ;-)

User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

Re: How to handle system freezes on SolydX

Postby ilu » 24 Apr 2015 15:14

Thanks Zill, that's 2 more possibilities I have to remember. And I have to print out the elefants in order not to forget them :oops:
I'm sorry if my questions seem redundant, but after 25+ years of MSWin I have a good idea about what to to do in case of errors and I know what kind of things will break when I hit the off-switch in mid-operation. Under Linux I have no idea and feel unsure because everybody tells you you should never do that. So far hitting the off-switch didn't produce any problems as far as I can see.
Does it make a diference for potential file corruption whether I use NTFS or EXT3?( I could change everything to EXT3 because the EXT-driver for WinXP seems to be reliable and I'm spending most of my time under Linux anyway now.)

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: How to handle system freezes on SolydX

Postby Zill » 24 Apr 2015 16:07

ilu wrote:... Does it make a diference for potential file corruption whether I use NTFS or EXT3?( I could change everything to EXT3 because the EXT-driver for WinXP seems to be reliable and I'm spending most of my time under Linux anyway now.)
I haven't gone anywhere near a Windows system for years so can't comment on NTFS.

You really should not be using ext3 for Linux systems as this was superseded by ext4 a long time ago. ext4 is a very reliable, modern, journalling file system and so will do its best to minimise any file corruption and recover properly following an incorrect shutdown. However, any filesystem can be damaged if you try and so it is always best to shut down properly (think elephants again!) after any misbehaviour as this will try to save all open files etc in the right sequence.

Bottom line: Use ext4 and always shut down properly.

kurotsugi
Posts: 2260
Joined: 09 Jan 2014 00:17

Re: How to handle system freezes on SolydX

Postby kurotsugi » 24 Apr 2015 16:53

you can't compare linux and windows. if your system is working it means that nothing is broken. in linux, your system do an automatic fsck at boot and with the journaling system of ext partition you can avoid data loss. if something were broken it will automatically restored. just to make sure, you can do a force fsck at boot by adding "forcefsck" on your boot parameter.

User avatar
ilu
Posts: 2654
Joined: 09 Oct 2013 12:45

Re: How to handle system freezes on SolydX

Postby ilu » 25 Apr 2015 02:32

Zill, as long as I have to read AND WRITE under both systems I can't use EXT4 because to my knowledge there is no reliable driver for Windows that can write EXT4. For executing files under both systems - which I need - there is no choice at all, only EXT3 (with the up to now very reliable help of Ext2IFS_1_11a.exe). Of course root is on EXT4 (and it is checked during boot), but not my data and not the programs installed under Wine.

Background, in case anybody is wondering: The government requires me (and every other german) to send in my tax declarations online. There is no Linux program doing that :evil: - only Mac and Win. I installed a Win program under Wine, which works - just not the update, which is necessary before sending the data. Because of that I have to update using WinXP which means, the code has to be executable under Linux/Wine and under Win (and Win has to write too). I have this problem with several programs.

User avatar
Zill
Posts: 1850
Joined: 13 Aug 2013 14:28
Location: Lincolnshire, UK

Re: How to handle system freezes on SolydX

Postby Zill » 25 Apr 2015 11:39

ilu: Thank you for the explanation and you have my sympathy! Being "forced" to use old and insecure proprietary software to complete government forms is disgraceful IMHO.

All I can suggest is that you lobby your elected representatives to use open-standards. You could consider signing this petition... "Germans petition for multi-platform tax return software"

Also, if it is only the official tax declarations that requires Windows then you could just use an old "clunker" PC for this and use your good Linux system(s) (with ext4) for everything else.


Return to “Newbie Questions”

Who is online

Users browsing this forum: No registered users and 14 guests