74.5 Issue: ScreenSaver Not Functional\Lubuntu 13.10 [140103]

On upgrading to Lubuntu 13.10 [131120] the screen-saver functionality stopped working on Kyral. This release of Lubuntu moved to using the display manager login screen rather than using xscreensaver for locking the screen. It may be that the migration in Lubuntu still has some way to go to iron out issues.

Using

$ dm-tool lock

displayed the GNOME display manager greeter (lightdm), but it did not lock the screen so that going back to our desktop with Ctrl-Alt-F7 we had un-locked access to the desktop immediately.

Also the screen blanking and locking was not automatically invoked on inactivity and on top of that the monitor was no longer being put to sleep.

We can remap Ctl-Alt-l from using xscreensaver to using gnome-screensaver, and that can then lock the screen, however it did not sleep the screen.

Using xfce4-power-manager-settings can put the screen to sleep after inactivity. However, xfce4-power-manager is not running on starting the LXSession. Under Preferences, choosing Default applications for LXSession, there are options for Screensaver and for Power Manager. Changing both to Other, which allows a command to be entered manually, and specifying the commands as gnome-screensaver and xfce4-power-manager respectively, and after a reboot, the screen now sleeps after inactivity but locking is not invoked. We can run the gnome-screensaver with above keyboard shortcut so we manually Ctrl-Alt-L to lock the screen and then the power manager kicks in to put the display to sleep. However, after a reboot even though xfce4-power-manager is running it is not acting. Deleting the config file in ~/.config/xfce/ sometimes rectifies the problem. But also, sometimes the mouse disapears after waking up. It all seems very flakey using xfce4-power-manager.

As a temporary fix, create ~/bin/lockscreen to contain these commands:

#!/bin/sh
dm-tool switch-to-greeter
sleep 5s
gnome-screensaver-command --lock
sleep 5s
xset dpms force off

Then make the script executable:

$ chmod u+x ~/bin/lockscreen

Edit the keyborad map in ~/.config/openbox/lubuntu-rc.xml to map Ctrl-Alt-l to ~/bin/lockscreen:

    <!-- Lock the screen on Ctrl + Alt + l-->
    <keybind key="C-A-l">
      <action name="Execute">
        <command>~/bin/lockscreen</command>
      </action>

To have this take effect in the current session run:

  $ openbox --reconfigure

Note that this does not change system settings so we might notice if a fix to Lubuntu configurations comes along. Also, Switch user crashes lightdm. At least we have a workaround for a manually invoked lock screen that also puts the monitor to sleep.

Some other things I tried included removing the xfce4-power-manager and set up gnome-screensaver and get it to lock and to put monitor to sleep by default, but didn’t get to the gsettings command that could configure the gnome-screensaver settings.

With gnome-screensaver running and the monitor put to sleep using xfce4-power-manager, the computer rebooted after about 30 minutes. Perhaps this was when gnome-screensaver kicked in. This hypothesis has not been tested.

It seems with Lubuntu 13.10 the autostart was disabled. We can go into Preferences and under Default appliactions for LXSession, go to the autostart tab and change the config-only to no. On re-login, at least gnome-screensaver is now running but the network manager applet (nm-applet) is running twice:

$ ps uaxx | grep screen
cpwil 15248  0.0  0.2 383340  8300 ?    Sl   11:46   0:00 gnome-screensaver
03 Jan 11:50:20 gjw@kyral:&nbsp;$ ps uaxx | grep nm
cpwil 15206  0.0  0.4 707792 17252 ?    Sl   11:46   0:00 nm-applet
cpwil 15227  0.0  0.4 699656 17260 ?    Sl   11:46   0:00 nm-applet

The screensaver does not seem to kick in as best I can tell—by waiting an hour. Also, running

  $ xfce4-power-manager-settings

complains that the power manager is not running, even if it is.

I reverted to config-only for the autostart, thus reverting to a single nm-applet running, and no gnome-screensaver. Then get xfce4-power-manager working again, but without screen lock. Not yet a solution.



Your donation will support ongoing availability and give you access to the PDF version of this book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984. Copyright © 1995-2022 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0