Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I disable the GNOME desktop screen lock? [closed]

How do I stop my GNOME desktop from locking the screen after a few minutes of idle time?

I already tried the official manual at Red Hat and tried to use gconf-editor and gconftool-2 to set /apps/panel/global/disable_log_out and /apps/panel/global/disable_lock_screen. No luck.

like image 519
Kashyap Avatar asked Feb 02 '15 15:02

Kashyap


Video Answer


2 Answers

On newer distributions of Linux, like Red Hat and CentOS 7, which run GNOME 3.x you'll want to disable this via the gsettings utility rather than gconftool-2. The default is 5 minutes before the system is considered idle. Setting the value to 0 disables this.

gsettings set org.gnome.desktop.session idle-delay 0

This setting can also be made in the GUI dconf-editor from a logged in session of the user in question.

From the standard System ToolsSettings application, there is also a "Blank Screen" option in the power settings which may provide the same behavior as the gsettings command given previously. In my testing, setting the "Screen Lock" to "Off" in the privacy settings DID NOT disable the screen blanking after 5 minutes.

On a final note, you cannot run that gsettings command from a remote SSH session without getting errors. See the last reference link below.

It was quite a research effort to get this disabled on my virtual machine!

References:

  • https://superuser.com/questions/727120/make-gnome-screen-lock-after-1-hour-not-15-minutes
  • https://askubuntu.com/questions/22313/what-is-dconf-what-is-its-function-and-how-do-i-use-it
  • https://superuser.com/questions/444896/gnome-settings-gsettings-vs-gconftool-2
  • https://askubuntu.com/questions/323776/gsettings-not-working-over-ssh
like image 112
Mark Edington Avatar answered Oct 24 '22 07:10

Mark Edington


The gconf schema entry for this in /etc/gconf/schemas/desktop_gnome_lockdown.schemas, and it would seem to be that the following command would disable the GNOME desktop lock screen:

 gconftool-2 --set /schemas/desktop/gnome/lockdown/disable_lock_screen --type boolean true

However, in reality it seems that no attention is paid to this parameter (in OL 7.2 anyways).

An effective, but clumsy, workaround is to navigate in the GUI to ApplicationSystemToolsSettingsPower and set PowerSaving Blank Screen to "Never".

like image 33
Quinn Carver Avatar answered Oct 24 '22 08:10

Quinn Carver