This forum has been archived. All content is frozen. Please use KDE Discuss instead.

[BUG] Automatic suspending won't work with external monitor

Tags: None
(comma "," separated)
User avatar
sparhawk
Registered Member
Posts
433
Karma
0
OS
I recently bought an external monitor for my laptop. With the monitor disconnected, automatic suspending works perfectly. With the monitor in use via the Mini Display Port (--output DP1), the laptop will no longer suspend automatically. How can I make this work with the monitor plugged in?

KDE 4.12.2
Kubuntu 13.10

Last edited by sparhawk on Wed Mar 19, 2014 2:33 am, edited 1 time in total.
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
Can you please elaborate on how automatic suspending isn't working? Does it simply not trigger at all, or does it freeze/hang part way through?
If it isn't triggering at all, is the laptop lid closed or open?


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
sparhawk
Registered Member
Posts
433
Karma
0
OS
Sorry, yes, suspending just doesn't trigger at all. I leave the laptop lid open in both situations. I have KDE set up to suspend session after 10 minutes.
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
Does initiating a suspend manually work?


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
sparhawk
Registered Member
Posts
433
Karma
0
OS
bcooksley wrote:Does initiating a suspend manually work?

Yes, the only broken is the automatic suspend that should trigger when I touch nothing for ten minutes.
User avatar
sparhawk
Registered Member
Posts
433
Karma
0
OS
I did a bit more troubleshooting. Firstly, I installed xprintidle to see if it agreed that my laptop was "inactive" (and should presumably be suspending). I looped it to run every minute, and it confirmed that my computer was "inactive", even though it didn't sleep automatically.

Then, I tried reducing the automatic suspend time to one minute. I leave the external monitor connected for all tests (via mini DisplayPort). With only the internal monitor active, my laptop suspends automatically. It fails when the external monitor is active, regardless of whether the internal is also active or not. I used the following commands to activate monitors.

Code: Select all
xrandr --output LVDS1 --auto --output DP1 --off # only internal monitor active. Works.
xrandr --output LVDS1 --off --output DP1 --auto # only external monitor active. Fails.
xrandr --output DP1 --auto --primary --output LVDS1 --auto --right-of DP1 # both active. Fails.


Oddly enough, if I test with Screen Energy Saving > Switch off after > 1 min, the screen will switch off (with dual monitors). So it seems that my computer does know it's "inactive" on some level.

==EDIT==
Also, there's no sign that the computer has undergone a quick suspend-resume cycle, from inspecting /var/log/pm-suspend.log .
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
As the system seems to believe it is idle, and does switch the screen off, I suspect this is a bug in Powerdevil which instead of just ignoring the lid closing for suspend when an external monitor is attached is instead ignoring all automatic attempts to suspend.

Please file a bug report at bugs.kde.org.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
sparhawk
Registered Member
Posts
433
Karma
0
OS
I thought I'd do one test before filing a bug report. With both monitors active, I tried closing the lid of the laptop. The computer actually suspended, which complicates that interpretation.

In any case, should I still file a Powerdevil bug?
User avatar
bcooksley
Administrator
Posts
19765
Karma
87
OS
Yes, please file a bug - I suspect the two issues may be interrelated - as the system shouldn't suspend when the lid is closed if an external monitor is connected.


KDE Sysadmin
[img]content/bcooksley_sig.png[/img]
User avatar
sparhawk
Registered Member
Posts
433
Karma
0
OS
bcooksley wrote:Yes, please file a bug


Bug filed here.

==EDIT==
Also, for the record, I'm using the following workaround in the meantime. Install xautolock then create the following file at ~/.config/autostart/automatic_suspend.desktop

Code: Select all
[Desktop Entry]
Comment=Workaround to https://bugs.kde.org/show_bug.cgi?id=331767
Exec=xautolock -time 10 -locker "dbus-send --system --print-reply --dest=org.freedesktop.UPower /org/freedesktop/UPower org.freedesktop.UPower.Suspend" -detectsleep &
Name=automatic_suspend
Type=Application


Bookmarks



Who is online

Registered users: Bing [Bot], daret, Google [Bot], Sogou [Bot]