I've recently installed Ubuntu 18.04 in a dual-boot configuration with Windows 10. I noticed today that, when trying to open system settings, Ubuntu seems to log me out to the lock screen. When I log back in, all previously-running applications are now closed. Very unsure what to do from here, any help much appreciated.
When I upgraded to 18.04 same problem happened to me. Ubuntu logs out unexpectedly and even after suspend. I figured out there was something wrong with
First of all remove
.Xauthority and then relogin using
sudo rm -v .Xauthority sudo service gdm restart
Don't worry system will recreate
Super late answer here, but for me it seemed to be a combo of nVidia drivers, greeter, and theme. When troubleshooting, particularly after an update, try reverting to one of the default themes via Gnome Tweaks, Adwaita, for example. It can sound trivial, but the semi-colon in the wrong place in ubuntu.css can prevent the system from booting.