Display powersave only blanks, but does not turn off

Bug #1971434 reported by Florian Echtler
248
This bug affects 51 people
Affects Status Importance Assigned to Milestone
gnome-settings-daemon (Ubuntu)
Confirmed
Medium
Unassigned
mutter (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

Recently upgraded to Ubuntu 22.04, and it seems like the power-saving feature in Gnome 42 does not actually turn off the screen(s) after X minutes, but just blanks them. When I manually run `xset dpms force off`, they do properly turn off and go to powersave mode.

1) Description: Ubuntu 22.04 LTS
   Release: 22.04

2) gnome-settings-daemon:
  Installed: 42.1-1ubuntu2
  Candidate: 42.1-1ubuntu2

3) In Settings -> Power -> Screen Blank, set the inactivity period to 5 minutes. After 5 minutes, the screens should turn off.

4) Screens go black, but remain active and consume (too much) power.
---
ProblemType: Bug
ApportVersion: 2.20.11-0ubuntu82
Architecture: amd64
CasperMD5CheckResult: unknown
CurrentDesktop: ubuntu:GNOME
DistributionChannelDescriptor:
 # This is the distribution channel descriptor for the OEM CDs
 # For more information see http://wiki.ubuntu.com/DistributionChannelDescriptor
 canonical-oem-somerville-bionic-amd64-20190418-59+beaver-osp1+X00
DistroRelease: Ubuntu 22.04
InstallationDate: Installed on 2020-07-04 (667 days ago)
InstallationMedia: Ubuntu 18.04 "Bionic" - Build amd64 LIVE Binary 20190418-12:10
Package: gnome-settings-daemon 42.1-1ubuntu2
PackageArchitecture: amd64
ProcVersionSignature: Ubuntu 5.15.0-27.28-generic 5.15.30
Tags: jammy
Uname: Linux 5.15.0-27-generic x86_64
UpgradeStatus: Upgraded to jammy on 2022-04-30 (3 days ago)
UserGroups: adm cdrom dialout dip lpadmin plugdev sambashare sudo vboxusers video wireshark
_MarkForUpload: True

Revision history for this message
Sebastien Bacher (seb128) wrote :

Thank you for your bug report. Could you do
$ apport-collect 1971434

do you use an xorg or wayland session and with which videodriver?

Changed in gnome-settings-daemon (Ubuntu):
importance: Undecided → Low
status: New → Incomplete
Revision history for this message
Florian Echtler (floe) wrote : Dependencies.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Florian Echtler (floe) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
Florian Echtler (floe) wrote : ProcEnviron.txt

apport information

Revision history for this message
Florian Echtler (floe) wrote :

I'm using Xorg 2:21.1.3-2ubuntu2, with kms on "Intel Iris Plus Graphics (G7)". Xorg.0.log attached as well.

Revision history for this message
Florian Echtler (floe) wrote :

One extra observation: when I use "xset dpms force off" to send the display to sleep, it stays in sleep indefinitely until the next user input, so apparently g-s-d never touches the power state.

Revision history for this message
Payam Nab (papampi) wrote :

Having same issue on Xorg with Nvidia-driver-510.

Revision history for this message
Tim (timw-suqld) wrote (last edit ):

Same issue on 22.04 Gnome Wayland session, Nouveau driver on a Geforce MX450 (Iris Xe Graphics onboard using i915 driver)

Fixed for me by moving to the nvidia proprietary driver

Revision history for this message
aurelijusr (aurelijus-rozenas) wrote :

Same on 22.04 Gnome Xorg, Nouveau driver on a GeForce GTX 1650 Ti Mobile

Revision history for this message
David Palacio (davplsm) wrote :

I had the same issue after upgrading to ubuntu 22.04 and the logs showed the following error.

Failed to connect to the screen saver: Error al llamar StartSereviceByName para org.gnome.ScreenSaver: Failed to execute program org.gnome.ScreenSaver: No such file or directory

The missing file was /usr/bin/gjs which I was able to solve by installing the gjs package. After restarting session the display powered off as espected.

I hope your problem is the same and you can solve it.

Revision history for this message
ed20900 (ed20900) wrote :

I'm on Wayland and I have the same problem. Ubuntu 22.04 upgraded from Ubuntu 20.04.

Revision history for this message
uunicorn (uunicorn) wrote :

Yep, installing gjs fixed the problem for me too: https://bugs.launchpad.net/ubuntu/+source/gnome-settings-daemon/+bug/1971434/comments/10

It also fixed the problem with custom keyboard shortcuts.

Revision history for this message
Cas (calumlind) wrote :

I am facing the same issue since upgrading from 20.04 to 22.04.

I have a Lenovo ThinkPad X1 Extreme Gen 3 with an external monitor (Dell P2720DC) connected via USB-C displayport that used to turn off completely but now only blanks with the backlight remaining on.

Display server: X11
Display driver: Nvidia 510.85.02

`xset dpms force off` turns off monitor correctly
gjs is already installed

Any help with debugging this would be useful since I don't see any issues in journalctl

I still need to test if Nvidia Prime profile has any effect (performance vs on-demand) or if same occurs under Wayland.

Revision history for this message
gazhay (gazhay) wrote :

Same issue, GJS already installed.

22.04 LTS
X11
Nvidia 515

gazhay (gazhay)
Changed in gnome-settings-daemon (Ubuntu):
status: Incomplete → Confirmed
Revision history for this message
Eric Slimko (slim0287) wrote :

I have the same issue.

22.04 LTS (though Pop!_OS 22.04)
Display server: X11
Display driver: Nvidia 515.48.07

gjs is already installed.

OS is installed on an iMac 14,2 from late 2013 (not dual boot, Linux is the sole operating system)

‘xset dpms force off’ does not turn off the monitor, it just blanks the screen.

Revision history for this message
gazhay (gazhay) wrote :

I am finding that display does turn off (following the fade to black) but within 20 to 30s the monitors turn back on and either remain on fully or just blank after a period of time but still powered.

Not convinced this is gnome-settings related and maybe this bug is in the wrong place?

Revision history for this message
gazhay (gazhay) wrote :

More appropriate project

affects: gnome-settings-daemon (Ubuntu) → gnome-screensaver
Revision history for this message
Romano Giannetti (romano-giannetti) wrote :

Adding data: there is something, probably lingering after the upgrade, that resets the `xdpm` data of the X server. After a while the screen starts to go off after very little inactivity, *without* enabling the screensaver (I blindy wrote my password in a couple of mails ;-)...).

If I set:

    xset dpms 600 600 600

it seems to work, is confirmed by `xset q`, but after a while (much less than 10 minutes) the screen goes off and when touching a key and checking, `xset` says:

$ xset q
[...]
DPMS (Energy Star):
  Standby: 0 Suspend: 0 Off: 0
  DPMS is Enabled
  Monitor is On

The only workaround I found is to completely disable dpms with `xset -dpms`; with tha the screensaver kicks-in correctly but then the display will never shut off...

Revision history for this message
Marc Deslauriers (mdeslaur) wrote :

gnome-screensaver is definitely the wrong package.

affects: gnome-screensaver → gnome-settings-daemon
Revision history for this message
Hany Said EL-Nokaly (hany-elnokaly) wrote :

Same issue. Apparently as many other bugs, Canonical will not fix it and we have to wait until next LTS release.

Revision history for this message
Philipp Wendler (philw85) wrote :
Download full text (3.1 KiB)

Sane issue here, but somewhat different setup than mentioned so far and more details:

- Ubuntu 22.04 with latest updates (Linux 5.15.0-48-generic, gnome-shell 42.4-0ubuntu0.22.04.1, mutter 42.2-0ubuntu1)
- gjs is installed
- occurs on both Wayland and X11
- amdgpu (AMD Ryzen 5 IGP)
- all Gnome extensions disabled except for standard extensions
- Problem exists even if I lock the screen immediately after logging in on a fresh session with no applications running except for a terminal.
- Problem exists also on the login screen if no user is logged in at all.
- When using an X11 session, "xset dpms force off" does not turn off the monitor.
- Back on 20.04, the screen successfully turned off under X11.

Log from "journalctl --user" covering the period of locking screen and logging in again a few minutes later:

Sep 22 10:41:48 server.passau systemd[42825]: Started Application launched by gnome-session-binary.
Sep 22 10:41:48 server.passau systemd[42825]: Started Application launched by gnome-session-binary.
Sep 22 10:41:50 server.passau pkexec[44266]: pam_unix(polkit-1:session): session opened for user root(uid=0) by (uid=1000)
Sep 22 10:41:50 server.passau update-notifier.desktop[44272]: [90B blob data]
Sep 22 10:41:50 server.passau update-notifier[44238]: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed
Sep 22 10:41:50 server.passau update-notifier[44238]: gtk_widget_get_scale_factor: assertion 'GTK_IS_WIDGET (widget)' failed
Sep 22 10:41:50 server.passau update-notifier.desktop[44272]: [163B blob data]
Sep 22 10:41:50 server.passau update-notifier.desktop[44272]: [101B blob data]
Sep 22 10:47:10 server.passau gnome-shell[42972]: JS ERROR: Failed to initialize fprintd service: Gio.DBusError: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name net.reactivated.Fprint was not provided by any .service files
                                                  asyncCallback@resource:///org/gnome/gjs/modules/core/overrides/Gio.js:114:23

Log from "journalctl --system" covering the same period (I removed networking-related log messages from SSH and systemd-networkd):

Sep 22 10:41:18 server.passau systemd[1]: systemd-hostnamed.service: Deactivated successfully.
Sep 22 10:41:18 server.passau systemd[1]: systemd-localed.service: Deactivated successfully.
Sep 22 10:41:43 server.passau rtkit-daemon[1875]: Supervising 5 threads of 3 processes of 1 users.
Sep 22 10:41:43 server.passau rtkit-daemon[1875]: Successfully made thread 44232 of process 42835 owned by '1000' RT at priority 5.
Sep 22 10:41:43 server.passau rtkit-daemon[1875]: Supervising 6 threads of 3 processes of 1 users.
Sep 22 10:41:47 server.passau geoclue[43043]: Service not used for 60 seconds. Shutting down..
Sep 22 10:41:47 server.passau systemd[1]: geoclue.service: Deactivated successfully.
Sep 22 10:41:50 server.passau pkexec[44266]: philipp: Executing command [USER=root] [TTY=unknown] [CWD=/home/philipp] [COMMAND=/usr/lib/update-notifier/package-system-locked]
Sep 22 10:47:14 server.passau gdm-password][44332]: gkr-pam: unlocked login keyring

If there is anything I can do to help debug this, I am glad to assist. If desired, I can also upload data with...

Read more...

Revision history for this message
gazhay (gazhay) wrote :

Can confirm #18 - same results here.

The only solution I have found so far is to run a script via crontab.
Check to see if monitor should be off "xset -q" looking for "Monitor is off"

If it is supposed to be off call
"xset dpms force suspend
sleep 2
xset dpms force off
"

This seems to get the monitors into standby mode - just forcing the off did not work for me - ymmv

This is an inelegant hack but it now means the monitors spend more time asleep than on which is progress.

This definitely isn't gnome-settings-daemon related but perhaps I wrongly assumed gnome-screensaver was what handled display sleep - this won't get the attention it needs here though.

Revision history for this message
Richard Brown (hypromangt) wrote (last edit ):

I have the same issue, migrating from 20.04 to 22.04.1 (worked fine on 20.04)
Asus N56VM laptop with a GeForce GT 630M

"xset dpms force off" will turn the display off properly.

Unfortunately, the cron approach described in #22 doesn't work on my system; when the screen blanks after inactivity, xset -q still reports that the "Monitor is On".

[edit: appended]
I came up with another hack/workaround that does work on my machine. The idea is to read the Settings->Power->"Screen Blank" idle timeout value from Gnome and use it to sync the DPMS timeout value using xset. I have this script running periodically via cron:

---- code snippet START ----
#!/usr/bin/env bash

IDLE_MINUTES=$(gsettings get org.gnome.desktop.session idle-delay | cut -d ' ' -f2)
X11_DISPLAY=:1
if [ -e "${HOME}/.X11_display" ]; then
    X11_DISPLAY=$(cat "$HOME/.X11_display")
fi
DISPLAY=${X11_DISPLAY} xset dpms 0 0 $IDLE_MINUTES
---- code snippet END ----

Setting DISPLAY is needed; otherwise xset can't interact with the X server. To achieve this, I've added the following code to my ~/.bashrc file:

---- code snippet START ----
# Record the X11 DISPLAY value if available
if [[ -n "${DISPLAY}" ]] && [[ ${DISPLAY} =~ ^:.* ]]; then
    echo "${DISPLAY}" > "${HOME}/.X11_display"
fi
---- code snippet END ----

Not perfect by any stretch, but better than a dark + backlit LCD screen.

Revision history for this message
Florian Echtler (floe) wrote :

One more datapoint: I noticed that this issue can be worked around for me when I manually lock the screen at least once using the Super-L hotkey. Before, the screens only blanked but didn't turn off; afterwards, they properly go into powersave.

Revision history for this message
Christopher Franz (hydraulic) wrote :

So this doesn't go down any dead-ends...

I have encountered this on:
20.04, both XFCE4 and GNOME
22.04, XFCE4

Using X11

When installed as a DE on Ubuntu Server, XFCE4 brings in a ton of GNOME deps so that may be covering the same territory. Xubuntu spin behaves similarly. I did -not-, however, experience it on a Kubuntu spin (all of the above were on the same hardware). Curious if that means all roads lead to GNOME (lol sorry!)

I see a prevalence of Nvidia users whenever I research this issue but in my case it's an AMD card on an AMD board, so we can cross that off as a vector (using AMDGPU in the kernel, none of the proprietary Pro stuff).

Leaving out blanking entirely has no effect; neither does disabling the DE power management and replacing it with XScreensaver. `xset -q` reports enabled and working, `xset dpms` will enable and disable as expected.

HTH

Revision history for this message
Kevin Milner (kevinmilner) wrote :

Not sure if related, but posting in case helpful to others who find this ticket.

I had an issue with the screen not going to sleep after upgrading from 20.04 to 22.04 and found this ticket. In my case, the screen wasn't blank but instead the gnome lock screen would stay on. I found that changing the "screen blank" time in settings did the trick. It was set to 15m and would lock but not blank (nor actually turn off the display); I changed the setting to 12m and then back to 15m and now it works again. Maybe some sort of issue in migrating settings on upgrade?

Revision history for this message
mbosi (mathieu-bosi) wrote :

I was having the very same problem.

The only (partial) workaround that worked for me was to delete the default "Super + L" lock-screen shortcut and replace it with a custom one using the same key combination and setting as command:

bash -c 'sleep 0.1 && xdg-screensaver lock && xset dpms force off'

This is based on these answers:
- Screen turns on automatically (xset dpms force off): https://unix.stackexchange.com/a/720365
- Setting custom shortcuts: https://help.ubuntu.com/stable/ubuntu-help/keyboard-shortcuts-set.html.en

Maybe the fact that a delay is necessary before of calling the `xset dpms force off` command might give some hint about why the bug might occur in the first place.

Now, the only missing part would be how to automate this same command after a given inactivity time, in a not too clunky way ...

Regards.

Revision history for this message
zezba9000 (zezba9000) wrote :

I have the same bug (and another I noticed looking into this).

* Ubuntu 22.04.2 LTS
* Processor: "AMD® Ryzen 7 7735hs with radeon graphics × 16"
* Graphics: "REMBRANDT (rembrandt, LLVM 15.0.6, DRM 3.47, 5.19.0-40-generic)"
* System: Minisforum UM773 Lite

So whats odd is I logged in with Wayland (I'm 100% sure of this).
However when I opened about in Ubuntu settings it said I was in X11.
So I logged out then back in again and now I'm on Wayland.

Ignoring the login bug, X11 seems to have this issue while Wayland does not.

Revision history for this message
Sadaharu Wakisaka (psw1747) wrote :

When I select "Power Saver" to 'Power Saving' mode, the display(s) turn off.
When I select "Power Saver" to 'Performance' mode, they don't.

Ubuntu 22.04 upgrade from 20.04. Optiplex 5090 i7-11700 Gnome/X.org
Ubuntu 20.04 doesn't have this bug.

Revision history for this message
T (reguluss) wrote :

Still have this problem on Ubuntu 22.04.2 LTS (i7-12700).

Both Wayland and X11 tried, no different.
gjs already installed.
Also tried to slected "Power Saver" to 'Power Saving' mode as [#30](https://bugs.launchpad.net/gnome-settings-daemon/+bug/1971434/comments/30) said, not work for me.

Also tried `xset dpms force off/standby`, the monitor goes off (really off not dark screen) but light again few seconds later. I didn't find any background process wake screen up (it's a new installed Unbuntu, only autossh/openssh running, not related).

other similar issue reports:
https://bugs.launchpad.net/ubuntu/+source/mutter/+bug/1998716
https://bugs.launchpad.net/ubuntu/+source/gnome-shell/+bug/1975557

affects: gnome-settings-daemon → gnome-settings-daemon (Ubuntu)
Changed in mutter (Ubuntu):
status: New → Confirmed
Revision history for this message
Force (force000) wrote :

I have the same issue, even with gjs installed and tried the other suggestions in this report.

I did upgrade from 21.10 (I think?) to 22.04. Even after a clean install with restoring the home folder, I still have the same problem.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

If you're using 22.04 then please try adding:

  MUTTER_DEBUG_ENABLE_ATOMIC_KMS=0

to /etc/environment and then rebooting.

Revision history for this message
David Beswick (dlbeswick) wrote (last edit ):

Hello Daniel, I'm on 22.04, I can confirm that adding the config in your #33 fixes the issue for me. I have Ryzen graphics.

Prior to the fix, running "xset dpms force off" resulted in the screen turning off and then turning on after a couple of seconds. After the fix, the screen stays off until input is entered, and the screensaver does turn off the monitor as expected.

Revision history for this message
JackyMatt (imyhxy) wrote :

I have confirmed that #33 method not working on Ubuntu 23.04.

Revision history for this message
Manel R. Doménech (manelio) wrote :

Ubuntu 23.04 with Intel Iris Xe Graphics. Same problem. Really annoying since my monitor doesn't hava a power button.

Revision history for this message
JackyMatt (imyhxy) wrote :

Yes, same configurations as #36 and same issue.

Revision history for this message
Dawn Smith (desm1th) wrote :

I'm on 22.04 and can also confirm that the fix in #33 worked for me. Thanks for the help Daniel!

Revision history for this message
JackyMatt (imyhxy) wrote :

Anyone has any idea what is going on here?

Revision history for this message
Philipp Wendler (philw85) wrote :

MUTTER_DEBUG_ENABLE_ATOMIC_KMS=0 from #33 also does not help here. Ubuntu 22.04, latest updates, kernel 6.2.0-35-generic, Wayland, integrated AMD GPU (more details about system in #21).

Revision history for this message
Razvan Matei Dedu (n6v26r) wrote :

The AtomicKms workaround did it for me. I'm on Manjaro gnome 45.

Revision history for this message
Sam Vervaeck (samvv) wrote :

For me the correct description of the bug was most likely given in [1].

When I use my laptop's screen, everything works fine. When I am using a Philips 275E UHD display, the behavior described in this thread appears.

Chances are that the KMS driver is doing something wrong.

I couldn't find an item on the Linux Kernel mailing list that addresses this (though it has been difficult to search). If someone knows more about how to debug this and file an issue, I'm all ears.

[1]: https://bugs.launchpad.net/ubuntu/+source/linux-raspi/+bug/1998716/comments/18

Changed in gnome-settings-daemon (Ubuntu):
importance: Low → Medium
Changed in mutter (Ubuntu):
importance: Undecided → Medium
Revision history for this message
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu ISO testing tracker.

A list of all reports related to this bug can be found here:
http://iso.qa.ubuntu.com/qatracker/reports/bugs/1971434

tags: added: iso-testing
Revision history for this message
Force (force000) wrote (last edit ):

The MUTTER_DEBUG_ENABLE_ATOMIC_KMS worked for me as well, thank you!

/edit: Unfortunately it stopped working again

Revision history for this message
Tim Richardson (tim-richardson) wrote (last edit ):

I use the wayland session. I sort of have this bug. The screens do power off, but then the backlights resume. It is still a blank screen
Update: this happened after I added a new monitor, a Lenovo ThinkVision, using HDMI. Swapping the connection to display port eliminated the problem

Revision history for this message
JackyMatt (imyhxy) wrote :

This bug is annoy.

I have test on Ubuntu 20.04, 22.04, 23.04, 24.04. All of them have the same bug on my machine.
And I also have tested on the HDMI and Display port on the motherboard side.

And when I switch to LightDM, the monitor can turn off but the lock screen shortcut won't work and I don't like LightDM very much.

My machine is i3-13700K on a Z790-PLUS motherboard, and no GPU.

Revision history for this message
Michał Fita (michal.fita) wrote :

This is Gnome bug I presume that manifests mostly on Ubuntu (clash with Canonical's tweaks) with some HDMI monitors (mostly Lenovo). The same monitors work as intended under Windows.

My bet is they send some message back to the computer when they change power state after requested to go to full power save. That in exchange wakes up the system, which ten keeps the screen blank, but backlight don't go off; they don't go off on both screens. If I turn off my Lenovo with switch, the laptop screen finally turns off after some time, but not always.

Revision history for this message
JackyMatt (imyhxy) wrote (last edit ):

I can confirm with #47, I have dual system on the same machine, Windows is works without issue, and Ubuntu does have.

My monitor is HDMI but not Lenovo.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Yes I too have believed for years there must be a feedback problem causing this. The reason it's still not fixed is just that it's so rare... every time I try to debug it the problem doesn't happen at all.

Revision history for this message
JackyMatt (imyhxy) wrote :

We should solve this issue before Earth Day. It has caused a lot of wastage of electricity.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.