0

For some reason, the lock screen has ceased to appear recently. I'm using 16.04, with the default Unity environment.

This problem seems to have occurred to others before, but none of those solutions work (for instance, here and here).

The Lock Super+L option appears in the system menu as normal, but it doesn't do anything (nor does hitting those keys). The system is set to show the lock screen upon waking up from suspend, but it no longer does so, it just immediately shows the desktop (well, a black box and the desktop, see the picture below).

Lock is on in System settings -> Brightness & Lock, as is Require my password when waking from suspend.

gsettings get org.gnome.desktop.lockdown disable-lock-screen is set to false.

gsettings get org.gnome.desktop.screensaver ubuntu-lock-on-suspend is set to true.

Also, this command always used to lock the screen, but now it does nothing: qdbus com.canonical.Unity /com/canonical/Unity/Session com.canonical.Unity.Session.Lock

I don't remember changing any configuration settings, nor have any relevant (I think) packages updated of late, which would imply a bug, but maybe I'm wrong on that. I do have x-screensaver installed, but it has worked fine for years.

Edit: the output of apt policy lightdm reads:

lightdm:
Installed: 1.18.3-0ubuntu1.1
Candidate: 1.18.3-0ubuntu1.1
Version table:
*** 1.18.3-0ubuntu1.1 500
    500 http://us.archive.ubuntu.com/ubuntu xenial-updates/main amd64 Packages
    500 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages
    100 /var/lib/dpkg/status
    1.18.1-0ubuntu1 500
    500 http://us.archive.ubuntu.com/ubuntu xenial/main amd64 Packages

I should also add that when the computer wakes from suspend, there's a black area that appears, which only becomes clear when a opening a window or something refreshes the screen.Ugly Disabling asking for password when waking from suspend in the system settings prevents the black screen from showing up, but, of course, that doesn't give me a screen lock.

  • I'm not 100% if they are related, but it sounds like a light-dm issue (the login screen). Can you try this command and let me know what it says : apt policy lightdm – jwcooper Apr 26 at 19:46
  • @jwcooper Edited my question to include that output. – Aibara Apr 26 at 23:06
  • Looks like lightdm is installed. Another user had some luck creating a new user on the system and that user was able to use the lock screen. If you want, you can try that and if it works we can work from there. Other than that, i'm not really sure. – jwcooper Apr 26 at 23:11
  • Also, when was the last time you updated the system. There was a bug reported similar to this launchpad that has been fixed. You can try sudo apt-get update && sudo apt-get dist-upgrade – jwcooper Apr 26 at 23:14
  • @jwcooper Hmm, dist-upgrade did nothing, but the lock screen works with the new user. At least I know it's not a missing package then. – Aibara Apr 26 at 23:58
1

The only answer I could come up with was based on this answer: Create New user to Restore missing lock screen

Basically, It states that you need to create a new user and migrate your home folder data to that user. It's not the best solution, but it seems to be the only working one I could find.

There was one more answer that I included in the comments above that you may want to check. You would need to check the passwordless login group and see if your username had been inadvertently added to that group. If it had, you would need to remove it with sudo gpasswd -d <USERNAME> nopasswdlogin. Also had you check lightdm and a few other things, but those solutions didnt seem to lead anywhere. Anyone else facing this problem should probably still start there though.

  • I did also check to see if the user was in the passwordless login group, but it was not. – Aibara May 1 at 15:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.