# Btrfs snapshot management

**URL:** <https://discuss.freedombox.org/t/btrfs-snapshot-management/2166>\
**Category:** Development\
**Created:** [July 9, 2022, 4:46pm UTC](https://discuss.freedombox.org/t/btrfs-snapshot-management/2166 "2022-07-09T16:46:42Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![joseph](https://discuss.freedombox.org/letter_avatar_proxy/v4/letter/j/dc4da7/32.png) [@joseph](https://discuss.freedombox.org/u/joseph)\
**Post date:** [July 9, 2022, 4:46pm UTC](https://discuss.freedombox.org/t/btrfs-snapshot-management/2166/1 "2022-07-09T16:46:42Z")

</div>

**Summary**  
Improve snapshot retention options to reduce excessive snapshot accumulation.

**Problem**

- Reboot snapshots accumulate quickly as one will be generated after each automatic update where reboot is required.
- Software installation snapshots may only be disabled or enabled.

I have read that retaining many snapshots may create performance problems for the system. It seems to me that the optimum number would be more than zero and less than too-many. Software install and reboot snapshots add up fast and may be taking users into the ‘too-many’ category.

**Solution**  
Create retention periods applicable to reboot and software installation snapshots.  
Perhaps these types of snapshots could use existing snapshot retention rules for timeline. Some dialog options could look like this…

_Reboot Snapshots_

- Retain using timeline rules
- Retain as Hourly, Daily, Weekly, Monthly, Yearly (Pick one)
- Custom retention interval (Select # of days to retain reboot snapshots)
- Do not remove automatically

_Software Installation Snapshots_

- Retain using timeline rules
- Retain as Hourly, Daily, Weekly, Monthly, Yearly (Pick one)
- Custom retention interval (Select # of days to retain reboot snapshots)
- Do not remove automatically

**Current State**  
A user may select individual snapshots to remove in the Storage Snapshots app. There is no automation for removal of reboot and software installation triggered snapshots.
