Skip to content

Feature Request: Allow multiple POST snapshots w.r.t. an existing PRE snapshot #764

@pinysuse

Description

@pinysuse

Issue

In case there is an existing pre - post snapshot pair, the attempt to create another, later post snapshot w.r.t. the same pre fails

Example

cat /.snapshots/116/info.xml
    [...]
      <type>pre</type>
      <num>116</num>
    [...]

this is our intended pre

cat /.snapshots/117/info.xml
    [...]
      <type>post</type>
      <num>117</num>
      <date>2023-01-04 11:34:35</date>
      <pre_num>116</pre_num>
    [...]

this is our existing post we want to replace with another later snapshot.
(we do not care at the moment whether we want to keep it still or can dispose of it...)

snapper create --type post --pre-number 116 --description "another post snapshot"
    Illegal snapshot.

Requested Feature

Allow more than one post snapshot.

In case of implications: Allow deletion of an existing post snapshot and creation of a new one

In the snapper GUI there could be new button Additional post snapshot next to the Modify button.
As second choice would be a new button Replace post snapshot.

Manual Work Around

Inspired by #24

btrfs subvolume delete /.snapshots/117/snapshot
    Delete subvolume (no-commit): '/.snapshots/117/snapshot'
rm -r /.snapshots/117
snapper create --type post --pre-number 116 --description "another post snapshot"
snapper list | tail -2  

    116  | pre    |       | Wed Jan  4 12:30:01 2023 | root |  96.00 KiB | number  | yast snapper                                   |              
    117  | post   |   116 | Wed Jan  4 13:52:22 2023 | root |  96.00 KiB |         | another post snapshot                    |              

(by chance again number 117 - could be any other higher increment due to intermediate (timeline) snapshots)
snapper diff 116..117

..works as intended

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions