Problem:
Ubuntu (18, 19, 10, 22, ...) with Gnome GUI crashes if you boot the machine and do not log into the GUI.
Precondition:
There is a GUI (should not apply to mere server installations)
Mostly some Gnome. Other flavours like "Ubuntu" or "Unity" may be concerned the same way. X and Wayland.
Symptoms:
GUI crashes completely after some 20 or so minutes.
Machine can not be reached by ssh any longer (often, not always, may vary).
Does not help:
Adjust the plenty of settings available via dconf-editor.
Nothing helps.
Remedy:
Change to a different Window Manager!
I managed to save many different desktop and laptop machines from crashing this way.
Changing to sddm or lightdm or even slim avoids the issue.
Just install and change it. Does not hurt and does NOT need a different desktop environment (you may stick to Gnome or whatever you prefer).
DISADVANTAGE
If there is light ... the lock screen may fail completely and some screen savers and even some sort of sleep / suspend mode may NOT work any longer!
This may be relevant for Laptops.
In fact you can NOT intertwine Gnome and other savers like in XFCE and then expect the energy savers to work properly!
XFCE has its own environment, Gnome has one.
Since XFCE does not cause the trouble with crashing GUI you will not have any issues sticking with clean XFCE or untainted LXDE and the like.
They are stable quality.
The mess comes with Gnome, as usual, here the pertaining gdm3 display manager.
You will only miss some energy saver functionality if gdm3 is not used.
The good news: You can switch back to gdm3 at any moment!
How to do that display manager magic?
A WM (window manager) is something different than a desktop environment! It's like shoes and feet ....
Just try to switch the WM (window managers). Right, it is not about installing the whole environment and stuff. The WM can stand alone, mostly.
No, it does not immediately kill your GUI - this is just about login and WM and I use it with Lunbuntu, XFCE4, Wayland, Gnome, Unity, Ubuntu-X, Ubuntu-Wayland, ....
So do not hesitate to run one of the config command just to try a different one. It is fun and it does not break anything (my personal experience).
I use it even with Ubuntu 22.04beta in the moment and it is fun!
Remark for newbie youngsters and mouse-junkies: Move with tab and choose with space bar. This is THE way to navigate.
What I really like are these:
(lovely! widely unknown WM login...)
(really light; avoids f***-up due to "energy saver" problems!)
(well known, convenient!! until it crashes your machine due to the "energy saver" bulls***; typical Gnome, looks good until you find out all the problems and shortcomings and design issues and pitfalls and unresolved issues and and and ...).
(you need to type your name and pwd - it is so slim it does not even offer drop down - very interesting experience, nice!) but you can switch desktops if different are available.
If one is not available just install it.
Mostly there will be hints. Just like:
would be one solution in the arena under a debian circus tent.
Do not miss this:
in the top left corner sddm and slim show the different available GUI flavours like Gnome, Unity, Ubuntu, w/o Wayland, XFCE etc. Choose before swaying at the display manager.
No, it does not show you a screwed up desktop after successful user login. Actually it shows the same options like gdm3 (Gnome) in a different way of layout.
So you retain the choice of desktop surface when you chose your display manager. Cool, isn't it?
And then?
Well, you can just switch them again and again! There is no issue in just using a different one if you do not like the current one any longer.
HELP!
I messed it up and the GUI does not start!
Easy solution:
ssh into the machine and invoke the usual
or one of the others (does not even matter! you get the choice in a GCLI-interface!). Choose different then reboot. Done.
Fun!
FF!
PS: If answer is somewhat helpful please do upvote - thanks!