System options

Snap supports a set of system-wide options that allow you to customise your snap environment.

As with Configuration in snaps, these options are changed with the set and get commands, but with a target of system instead of a specific snap:

$ snap set system some.option="some value"
$ snap get system some.option

Configuration options can be unset by either passing their names to the unset command or by adding an exclamation mark (!) to the end of an option name: (from snapd 2.41+):

$ snap unset system some.option
$ # or
$ snap set system some.option!

If a setting is part of the system snap, provided by either the core snap or snapd itself, the command syntax will include two instances of system, such as with system.timezone:

$ snap set system system.timezone="Europe/London"  

Typing snap get system outputs a top-level view of system-wide option categories which can be added as arguments to view their contents:

$ snap get system
Key           Value
experimental  {...}
refresh       {...}
seed          {...}
system        {...}
$ snap get system experimental
Key                   Value
experimental.hotplug  true
experimental.layouts  true

The entire set of system configuration options can be dumped as JSON by adding the -d option:

$ snap get -d system
        "experimental": {
                "hotplug": true,
                "layouts": true,
                "quota-groups": true
        "refresh": {
                "last": "2017-05-25T09:03:58.664837614+01:00",
                "retain": 2
        "seed": {
                "loaded": true
        "system": {
                "hostname": "neon",
                "network": {},
                "timezone": "UTC"

Note: Options are not visible until after they are set. The snap get command can then be used to check their state.


On a Raspberry Pi, the following options set corresponding values in the config.txt system configuration file:

  • pi-config.disable-overscan
  • pi-config.framebuffer-width
  • pi-config.framebuffer-height
  • pi-config.framebuffer-depth
  • pi-config.framebuffer-ignore_alpha
  • pi-config.overscan-left
  • pi-config.overscan-right
  • pi-config.overscan-top
  • pi-config.overscan-bottom
  • pi-config.overscan-scale
  • pi-config.display-rotate
  • pi-config.hdmi-group
  • pi-config.hdmi-mode
  • pi-config.hdmi-drive
  • pi-config.avoid-warnings
  • pi-config.gpu-mem-256
  • pi-config.gpu-mem-512
  • pi-config.gpu-mem

Further details on the above, see the official Raspberry Pi documentation.


These options may be set to change the proxies to be used by the system when communicating with external sites that speak the respective protocols.

Available since snapd 2.28.


There are four system-wide options that are used to manage how updates are handed:

  • refresh.timer: defines the refresh frequency and schedule
  • refresh.hold: delays the next refresh until the defined time and date
  • refresh.metered: pauses refresh updates when network connection is metered
  • refresh.retain: sets how many revisions of a snap are stored on the system

See Controlling updates for further details on how the above options are used.


This option adjusts the Linux kernel’s out-of-memory (OOM) killer behaviour for specific snap services.

By default, all snap services have the same value for systemd’s OOMScoreAdjust. By passing a list of snaps ordered by decreasing importance to the resilience.vitality-hint system option, the order is respected if snap processes are killed in low memory situations.

The list of snaps need to be as string containing comma separated snap instance names in decreasing order of importance, such as:


In the above example, services inside snapA are the least likely to be killed in out of memory situations, followed by services in snapB, services in snapC, and then the services in all the other snaps not referenced by the vitality-hint option.

:information_source: Snaps added to resilience.vitality-hint are still more likely to be killed than the snap daemon, snapd, itself.

Available since snapd 2.46.


May be set to true to disable the console-conf system configuration wizard that is launched by default when booting an initialised Ubuntu Core image.

Available since snapd 2.46.


May be set to true to disable the SSH service at startup.

Available since snapd 2.22.


Automatic snapshot retention time is configured with the snapshots.automatic.retention system option. The default value is 31 days, and the value needs to be greater than 24 hours:

$ snap set system snapshots.automatic.retention=30h

To disable automatic snapshots, set the retention time to no:

$ snap set system snapshots.automatic.retention=no

Disabling automatic snapshots will not affect preexisting, automatically generated snapshots, but only those generated by subsequent snap removals.

Automatic snapshots require snap version 2.39+.


A custom SSL certificate can be added to snapd’d trusted certificates pool for the store communication with the store-certs.<name>=<value> system option.

To add a certificate, enter the following:

$ snap set system store-certs.cert1="$(cat /path/to/mycert)"

A certificate can be removed with unset:

$ snap unset system store-certs.cert1

Available since snapd 2.45


May be set to true to disable the backlight service.

Available since snapd 2.46.


Enables or disables journal persistence. Can be true or false. If persistent journals were previously enabled by this setting, changing the value to false will delete all saved logs.

Example to enable the journal:

$ snap set system journal.persistent=true

Available since snapd 2.45.


Override the console log level with a number between 0 and 7.

The configuration will be stored in /etc/sysctl.d/99-snapd.conf and the default value is 4

Example to set the log level to 1:

$ snap set system system.kernel.printk.console-loglevel=1
$ cat /etc/sysctl.d/99-snapd.conf 
kernel.printk = 1 4 1 7

Available since snapd 2.46.


Defines the behaviour of the system when the power key is pressed.

May be set to one of:

  • ignore
  • poweroff
  • reboot
  • halt
  • kexec
  • suspend
  • hibernate
  • hybrid-sleep
  • lock

Available since snapd 2.23.


May be used to set a time zone value, as typically found in /usr/share/zoneinfo, such as America/Chicago.

$ snap set system system.timezone="America/Chicago"

To see the current timezone settings, use the snap get -d system:

$ snap get -d system
        "experimental": {
                "hotplug": true,
                "layouts": true
        "refresh": {
                "last": "2017-05-25T09:03:58.664837614+01:00",
                "retain": 2
        "seed": {
                "loaded": true
        "system": {
                "timezone": "America/Chicago"

Available since snapd 2.46.


Configures the system’s hardware watchdog runtime timeout.

The watchdog runtime timeout is an interval during which the system manager must contact the hardware watchdog to prevent a device from being automatically rebooted. Usage of this feature requires corresponding hardware support as the watchdog hardware, /dev/watchdog or the kernel option systemd.watchdog-device=, will be programmed to automatically reboot the system when not contacted within the specified timeout interval.

A valid value is a non-negative time duration in seconds, or suffixed with ms, min, h, d, w for milliseconds, minutes, hours, days and weeks respectively.

The following example will set the timeout to 1 minute:

$ snap set system watchdog.runtime-timeout=1m

Available since snapd 2.34.


Configures the system’s hardware watchdog shutdown timeout.

The watchdog shutdown timeout is an interval to permit a clean reboot of the system. If the system fails to reboot within this interval, the watchdog will forcibly restart the system to protect against failed or hanging reboots. Usage of this feature requires hardware support.

Note that the shutdown-timeout applies only to the second phase of a reboot, after all regular services are terminated and the system and service manager process has been replaced by the systemd-shutdown binary.

As with the watchdog runtime timeout, a valid value is a non-negative time duration in seconds, or suffixed with ms, min, h, d, w for milliseconds, minutes, hours, days and weeks respectively.

The following example will set the timeout to 500 seconds:

$ snap set system watchdog.shutdown-timeout=500

Available since snapd 2.34.

Last updated 5 days ago.