44

I've just installed Ubuntu 18.04 and I want to disable the lock screen. I don't want to see it at all, neither on power-on nor after suspension.

I tried:

Settings -> Privacy -> Screen Lock -> and changed 'Automatic Screen Lock' to 'Off'.

The lock screen still appears after suspension.
Any suggestions?

K7AAY
  • 17,202
  • 8
    None of the answers seem to actually completely turn off that slider screen that appears when idle. – tresf Feb 09 '19 at 04:14
  • 2
    @tresf I got rid of the slider with the command from this answer – if it helps you as well please upvote it so it rises! – dessert Oct 08 '19 at 12:18
  • In Xubuntu 18.04 you could switch locking on sleep in Power Manager dialog. In Xubuntu 19.10 also in Screensaver (Preferences) dialog. – jarno Dec 31 '19 at 01:04
  • still relevant in 20.04. major bug. so much facepalm. – Chaim Eliyah Oct 03 '20 at 01:48
  • Guys, I just tried what @Nadav said and... well it worked for me... left my pc unattended for quite a while. The screen did went black but after moving my mouse no lock screen... perhaps it's fixed now? – DarkCygnus Dec 21 '21 at 22:30

3 Answers3

68

Disable Lock Screen

You can disable the lock screen permanently when waking from suspend.

First use this command to discover current settings:

$ gsettings get org.gnome.desktop.lockdown disable-lock-screen
false

Now set it to true using this command:

gsettings set org.gnome.desktop.lockdown disable-lock-screen 'true'

If you are unhappy with the new setting you can reverse it using:

gsettings set org.gnome.desktop.lockdown disable-lock-screen 'false'

Disable Screen Saver Locking

There was some confusion where people think disabling the Lock screen also disables the screen saver which is invoked after a certain period of inactivity. The screen saver requires input to get your desktop back. Some people may want the screen saver to come on but not have it locked when waking up the screen.

To check screen saver lock status use:

$ gsettings get org.gnome.desktop.screensaver lock-enabled
true

If true you can turn off screen saver locking with:

gsettings set org.gnome.desktop.screensaver lock-enabled false

To reverse the setting back use:

gsettings set org.gnome.desktop.screensaver lock-enabled true

In Gnome screen locking guide it says:

6.2. Screen Locking

By default, GNOME Power Manager supports a simple locking scheme. This means that the screen will lock if set to Lock screen in gnome-screensaver when the lid is closed, or the system performs a suspend or hibernate action.

There is a complex locking scheme available for power users that allows locking policy to change for the lid, suspend and hibernate actions. To enable this complex mode, you will have to disable the GConf key:

  • /apps/gnome-power-manager/lock/use_screensaver_settings

Then the policy keys can be set to force a gnome-screensaver lock and unlock when the action is performed:

  • /apps/gnome-power-manager/lock/blank_screen
  • /apps/gnome-power-manager/lock/suspend
  • /apps/gnome-power-manager/lock/hibernate
  • 2
    Sounds very promising, but doesn't make any difference for me. I've changed the setting to true but the "privacy" screen still comes over the desktop after a period of time. Turning off locking in the system settings means I don't have to re-enter my password, but I still need to swipe the screen up to get back to where I was. Fresh Ubuntu Desktop 18.04.1 install. – Heath Raftery Sep 14 '19 at 02:33
  • @HeathRaftery There is another option to try as listed below: gsettings set org.gnome.desktop.screensaver lock-enabled false – WinEunuuchs2Unix Sep 15 '19 at 15:58
  • 1
    @HeathRaftery On my system, you can hit escape instead of swiping up with the mouse. Still annoying, but perhaps not as awful as the swipe gesture. And +1 to the thought that this answer isn't a solution to the problem, unfortunately. – James Moore Sep 29 '19 at 16:30
  • Well lock-enabled did the trick, but now I can't undo it! – Heath Raftery Oct 02 '19 at 06:34
  • after setting both lockdown disable-lock-screen 'true' and screensaver lock-enabled false I still get a big clock after wakening the screen on Ubuntu 18.04.3 LTS :-( – pjvleeuwen Dec 30 '19 at 20:39
  • 1
    I found this answer after my screen lock mysteriously stopped working (no password required after waking from sleep, and Super+L suddenly did nothing). Settings > Privacy > Screen Lock showed all three screen lock controls as disabled. After running gsettings set org.gnome.desktop.lockdown disable-lock-screen false the controls were working again and screen lock worked as expected. – Rob Flickenger Mar 03 '20 at 16:40
  • What actually worked for me was using dconf read /org/gnome/desktop/screensaver/lock-enabled to get the value and dconf write /org/gnome/desktop/screensaver/lock-enabled false to disable the screen saver. Can use as-is with Ansible dconf module. – Martin Tapp Sep 21 '22 at 13:56
9

Try this approach:

  1. Launch terminal
  2. Run gsettings set org.gnome.desktop.screensaver lock-enabled false

This is a solution from this FOSSLinux source.

1

How about this:

gsettings set org.gnome.desktop.screensaver ubuntu-lock-on-suspend false
Hank W
  • 27