openSUSE and SLES use the btrfs filesystem by default, with snapper set up to create automatic snapshots. These snapshots are triggered periodically, through system changes made with YaST2 or zypper. While snapshots are useful for system recovery, they can quickly consume disk space, especially in environments with limited storage.

You can disable these automatic snapshots to conserve disk space. This is particularly beneficial in virtual machines where storage is often constrained. Disabling snapshots can be done by modifying snapper configurations and removing specific plugins.

The process involves removing the snapper plugin for zypper, disabling snapper's timeline snapshots, and disabling snapshots created by YaST. These steps will prevent automatic snapshots from taking up unnecessary disk space.

Step-by-step video guide:

Remove snapper plugin for zypper

Removing the snapper plugin for zypper prevents the automatic creation of snapshots during software installation, removal, or updates. This method is essential for reducing disk space usage associated with frequent system changes managed through zypper.

> sudo zypper remove --no-confirm snapper-zypp-plugin
Loading repository data...
Warning: No repositories defined. Operating only with the installed resolvables. Nothing can be installed.
Reading installed packages...
Resolving package dependencies...

The following package is going to be REMOVED:
  snapper-zypp-plugin

1 package to remove.
After the operation, 9.8 KiB will be freed.
Continue? [y/n/v/...? shows all options] (y): y
(1/1) Removing snapper-zypp-plugin-0.8.3-1.1.noarch ..............................[done]

Disable snapper's timeline snapshots

Disabling snapper's timeline snapshots stops the hourly automatic creation of snapshots, which can rapidly consume disk space. This method is crucial for environments where frequent snapshots are unnecessary and storage is limited.

  1. List available available snapper configs.
    > sudo snapper list-configs
    [sudo] password for root: 
    Config | Subvolume
    -------+----------
    root   | /
  2. Disable timeline snapshot for specific config.
    > sudo snapper --config root set-config "TIMELINE_CREATE=no"

Disable YaST snapshots

Disabling snapshots triggered by YaST stops the creation of filesystem snapshots whenever configuration changes are made. This method helps in conserving disk space, especially in systems where YaST is frequently used for system management.

  1. Open YaST configuration file using your preferred text editor with root permission.
    > sudo vi /etc/sysconfig/yast2
  2. Search for USE_SNAPPER and set the value to no.
    USE_SNAPPER=no
Discuss the article:

Comment anonymously. Login not required.