B-tree file system (btrfs) Snapper config not found

This document (7012012) is provided subject to the disclaimer at the end of this document.

Environment

SUSE Linux Enterprise Server 11 Service Pack 2
B-tree Filesystem (btrfs)

Situation

The /etc/sysconfig/snapper has all the expected configurations, but they do not show up in snapper list-configs. No additional snapshots are being generated on the subvolume.

# snapper list-configs
Config | Subvolume 
-------+------------
bsmall | /bsmall   
bbig   | /bbig     
one    | /bbig/one 
heart  | /bbig/heart

However, /etc/sysconfig/snapper shows: SNAPPER_CONFIGS="bsmall bbig fry one heart". In this case the "fry" configuration is missing.

# ls /etc/snapper/configs
bbig  bsmall  heart  one

Attempting to list the fry configuration fails:

# snapper -c fry list
Config 'fry' not found.

Attempting to create the fry configuration again fails:

# snapper -c fry create-config /bsmall/fry
Creating config failed (config already exists).

The /var/log/snapper.log shows the following errors:

WARNING libsnapper(10649) AsciiFile.cc(AsciiFileReader):55 - open for '/etc/snapper/configs/fry' failed
ERROR libsnapper(10649) Snapper.cc(getConfigs):536 - config 'fry' not found

Resolution

Restore the configuration file from backup or recreate it manually. To recreate a configuration file, do the following:
NOTE: In this example the snapper config name we need to restore is "fry"
1. cp /etc/snapper/config-templates/default /etc/snapper/configs/fry
2. Make sure you know which subvolume the "fry" configuration is maintaining. In this case /bsmall/fry is the path.
# btrfs subvolume list /bsmall
ID 256 top level 5 path @
ID 258 top level 5 path @/fry
ID 259 top level 5 path @/.snapshots
ID 260 top level 5 path @/fry/.snapshots
ID 261 top level 5 path @/.snapshots/1/snapshot
ID 262 top level 5 path @/fry/.snapshots/1/snapshot
ID 263 top level 5 path @/.snapshots/2/snapshot
ID 264 top level 5 path @/.snapshots/3/snapshot
ID 265 top level 5 path @/.snapshots/4/snapshot
ID 266 top level 5 path @/fry/.snapshots/2/snapshot

3. Edit /etc/snapper/configs/fry
4. Replace SUBVOLUME="/" with SUBVOLUME="/bsmall/fry"
5. Save and exit /etc/snapper/configs/fry
6. Run snapper list-configs and snapper -c fry list to test.

Cause

The /etc/snapper/configs configuration file was deleted.

Disclaimer

This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.

  • Document ID:7012012
  • Creation Date: 22-Mar-2013
  • Modified Date:03-Mar-2020
    • SUSE Linux Enterprise Server

< Back to Support Search

For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback[at]suse.com

SUSE Support Forums

Get your questions answered by experienced Sys Ops or interact with other SUSE community experts.

Join Our Community

Support Resources

Learn how to get the most from the technical support you receive with your SUSE Subscription, Premium Support, Academic Program, or Partner Program.


SUSE Customer Support Quick Reference Guide SUSE Technical Support Handbook Update Advisories
Support FAQ

Open an Incident

Open an incident with SUSE Technical Support, manage your subscriptions, download patches, or manage user access.

Go to Customer Center