GNOME 2.0 Desktop for the Solaris Operating Environment System Administration Guide

To Set Preference Values

You can set a mandatory value or a default value for a preference key. Before you change mandatory preference values or default preference values for users, you must ensure that the GConf daemon is not running for any user. Ensure that all users are logged out before you change preference values for users.

To set a mandatory value or a default value for a preference key, use the gconftool-2 command, as follows:

# gconftool-2 --direct --config-source configuration-source --type data-type --set preference-key value

For example, to set wwwproxy.xyz.com as the mandatory HTTP proxy host, run the following command:

# gconftool-2 --direct --config-source xml:readwrite:/etc/gconf/gconf.xml.mandatory --type string --set /system/http_proxy/host wwwproxy.xyz.com

The user cannot override this preference value.

You can also use the gconftool-2 command to set default values. For example, to set the default number of workspaces to five, run the following command:

# gconftool-2 --direct --config-source xml:readwrite:/etc/gconf/gconf.xml.defaults --type int --set /apps/metacity/general/num_workspaces 5

The user can override this preference value.


Caution – Caution –

Before you change mandatory preference values or default preference values for users, you must ensure that all users are logged out.