| name | setup-snapper-config |
| description | Use when the user wants snapper to start managing a subvolume. |
Setup Snapper Config
Initialize snapper management for a BTRFS subvolume that isn't yet covered.
When to use
- First-time setup of snapper on a subvolume
- Extending snapper to a new mount point
- Establishing retention policies for a partition
Inputs to gather
- Config name (e.g.,
root, home)
- Mount path (e.g.,
/, /home)
- Retention preferences (optional; timeline snapshots, keep-last count)
Procedure
- Preflight: Verify mount path is BTRFS with
stat -f -c %T <path>. Verify snapper is installed.
- Run
sudo snapper -c <name> create-config <path>.
- List the created config at
/etc/snapper/configs/<name> and ask user about retention:
TIMELINE_CREATE (auto hourly snapshots; yes/no)
NUMBER_LIMIT (keep-last count; suggest 5–10)
- If user provides values: Edit
/etc/snapper/configs/<name> with new settings.
- Confirm snapper is running:
sudo systemctl status snapper-timeline.timer.
Output / side effects
Snapper config created and initialized. Timeline snapshots may start automatically if TIMELINE_CREATE=yes.
Safety / constraints
Modifies /etc/snapper/configs/. Requires sudo. Should not touch system files outside the snapper config directory.