🔍 See Original Answer on Ask Ubuntu ⧉ 🔗
Configure screensaver in Ubuntu
August 30, 2018
Edited: May 22, 2019
December 3, 2023
Copy to clipboard: false
/assets/js/search.js will update text..
Radu’s answer is a good one so I won’t duplicate it. I will point out extra steps recommended by the
xscxreensaver developer. I’m also including a short paragraph of history from the developer.
##USING GNOME OR UNITY
For the better part of a decade, GNOME shipped
and everything just worked out of the box. In 2005, however, they
decided to re-invent the wheel and ship their own replacement for the
xscreensaver daemon called “gnome-screensaver”, rather than improving
xscreensaver and contributing their changes back. As a result, the
“gnome-screensaver” program is insecure, bug-ridden, and missing many
features of xscreensaver. You shouldn’t use it.
To replace gnome-screensaver with xscreensaver:
Fully uninstall the gnome-screensaver package.
sudo apt-get remove gnome-screensaver
Launch xscreensaver at login.
Select “Startup Applications” from the menu (or manually launch “gnome-session-properties”) and add “xscreensaver”.
Make GNOME’s “Lock Screen” use xscreensaver.
sudo ln -sf /usr/bin/xscreensaver-command /usr/bin/gnome-screensaver-command
That doesn’t work under Unity, though. Apparently it has its own built-in screen locker which is not gnome-screensaver, and cannot be
removed, and yet still manages to be bug-addled and insecure. Keep
reinventing that wheel, guys! (If you have figured out how to replace
Unity’s locking “feature” with xscreensaver, let me know.)
Turn off Unity’s built-in blanking.
Open “System Settings / Brightness & Lock”;
Un-check “Start Automatically”;
Set “Turn screen off when inactive for” to “Never.”
I do not agree with the strong language of the developer but felt it better to include the history rather than hide it.
Ubuntu 18.04 special notes
Many have complained when locking screen with Ctrl+Alt+L external monitors blank instantly and those with dpms are switched off. This causes unwanted delays when unlocking screen. Using
xscreensaver will circumvent that particular problem.
You can decommission the Ctrl+Alt+L shortcut from
gnome-screensaver and assign it to a new command for
This keyboard shortcut reassignment also works in Ubuntu 16.04.