1

When sitting at the lock screen, such as upon initial boot, the system never goes to sleep. However, once logged in sleep works just fine.

Should it be going to sleep at the lock screen? If so, how do I go about figuring out what is preventing sleep?

Running 16.04 if that makes any difference.

patrick
  • 11

1 Answers1

0

Thanks to FredFoo's comment for getting me on the right track, and the post at How to let screen time out on sign in screen, I was able to figure out that the user for the login screen is lightdm.

Run this to find all of the lightdm user's power settings:

sudo -H -u lightdm dbus-launch --exit-with-session gsettings list-recursively org.gnome.settings-daemon.plugins.power

Then run this similar command to see the current user's power settings:

gsettings list-recursively org.gnome.settings-daemon.plugins.power

Based on the above I was able to figure out that the setting I needed was sleep-inactive-ac-timeout, which was set to 0 for the lightdm user but was set to 300 for my personal user.

Then I ran:

sudo -H -u lightdm dbus-launch --exit-with-session gsettings set org.gnome.settings-daemon.plugins.power sleep-inactive-ac-timeout 300

to set the same timeout, restarted, and everything is now working as expected.

patrick
  • 11