The directory you need for this is
/etc/dconf/db/local.d/locks
The are not stored there though; this is the place to put them to make one read-only. From dconf admininstration ...
Lockdown
Lockdown is supported by creating a 'locks' subdirectory in the keyfile directory (ie: /etc/dconf/db/local.d/locks). The files contained in this directory contain a list of keys to lock, one per line. Just as with the keyfiles, you may add any number of files to this directory. Here's an example of what one might look like:
# prevent changes to the company wallpaper
/org/gnome/desktop/background/picture-uri
Of course, you need to run the 'dconf update' tool after changing the locks. The tool will notice if the timestamp on the 'locks' directory has changed, so there is no need to touch the ".d" directory as well.
The lockdown key for hide-mode should be ...
/com/canonical/unity-2d/launcher/hide-mode
I would consider it a bug if this does not work.
Alternative ...
You could add this to some script or ~/bashrc or something else to get it reset.
18.04 used gdm3.
DConf configuration
Some GDM settings are stored in a DConf database. They can be configured either by adding keyfiles to the /etc/dconf/db/gdm.d directory and then recompiling the GDM database by running dconf update as root or by logging into the GDM user on the system and changing the setting directly using the gsettings command line tool. Note that for the former approach, a GDM profile file is required - this must be created manually as it is no longer shipped upstream, see below:
/etc/dconf/profile/gdm
user-db:user
system-db:gdm
file-db:/usr/share/gdm/greeter-dconf-defaults
In /etc/dconf/db/gdm.d
you can create a file per key in the sty
rinzwind@schijfwereld:/etc/dconf/db/gdm.d$ ls
02-logo
rinzwind@schijfwereld:/etc/dconf/db/gdm.d$ more 02-logo
[org/gnome/login-screen]
logo='/discworld/Pictures/Wallpapers/Nier.9.jpg'
And this will preseed the value in dconf.
More examples in the link.
/etc/dconf/db/local.d/locks/unity-2d
, containing# keep Unity-2D in dodge
/com/canonical/unity-2d/launcher/hide-mode
, but that doesn't work. Changing the path to/com/canonical/Unity2d/Launcher/hide-mode
doesn't work either. – Exeleration-G May 05 '12 at 22:57sudo dconf update
(I removed locks and created a new dir lock and it complained about it). – Rinzwind May 06 '12 at 06:56automount
key, in relation to the 'org.gnome.desktop.media-handling' schema. I am using 16.04. I have created this question: https://askubuntu.com/questions/1038184/how-to-lockdown-system-wide-settings-with-dconf. The only system database I have showing in/etc/dconf/db
is 'ibus.d'. I have created a key file and appropriate file in the 'locks' subdirectory, as per the documentation quoted. I cannot see what I am doing wrong? – Andrew Hardiman May 20 '18 at 19:08