Trisquel (MATE) - double passwort input when switching users
Hi!
We have two users of the same computer. However whenever we switch the user, the other user has to enter the password twice. Once for the typical login screen (same one as on first boot) and once for the screensaver! This is rather annoying. Does anyone know how to fix this?
What we already tried: In the screensaver-settings we tried to disable the screensaver when the user is idle but this didn't seem to have any effect.
Which screensaver packages do you have installed?
Try in a terminal:
dpkg -l '*screensaver*'
Apparently:
mate-screensaver
mate-screensaver-common
trisquel-screensaver
You can disable the screen lock from the terminal with:
gsettings set org.mate.screensaver lock-enabled false
or uncheck the corresponding box in System > Preferences > Look and Feel > Screensaver.
Setting this in the preferences or via gsettings works if the user is actually idle or if the user calls "mate-screensaver-command --activate" but this doesn't work in the "switching user" scenario (password input twice if the user already has a running session because mate-screensaver-command --lock is called internally).
However, I found a somewhat elegant solution to this based on a hook.
0. (option) Disable locking as prospero suggested but it works with enabled locking too
1. move the existing mate-screensaver-command:
cd /usr/bin
sudo mv mate-screensaver-command mate-screensaver-command-actual
2. write a small script that intercepts the lock-command and calls the switch-user-dialog instead:
sudo vi /usr/bin/mate-screensaver-command
#!/bin/sh
if [ "$1" = "--lock" ]; then
dm-tool switch-to-greeter
else
mate-screensaver-command-actual $1
fi
3. finally make it executable:
sudo chmod 755 /usr/bin/mate-screensaver-command
I kind of like this solution because having 2 types of Login-Screens is redundant anyways and it integrates nicely. It also works with "Super+L"-Shortcut or if the user clicks the lock-option in the startmenu. However the downside is that I have to do this again in case mate-screensaver-command updates from a package but I can live with that.

