I’m using restic to backup a huge amount of data from my laptop (>1TB), on a pretty slow link.
Is there a way to create the snapshot ID before the whole data were transferred? It would make them easily available for restore, should a crash come before backup ends.
In this case, a supplemental switch (similar to --parent) could be used to continue the backup in the same snapshot.
The snapshot ID is a hash of the snapshot object, which contains the root tree object ID. Tree IDs are a hash of their contents, and so on.
So no, the ID of a snapshot depends on its contents so it cannot be computed in advance.
restic recover can create snapshots from orphaned tree objects in the repository. If you need to restore data that hasn’t been assembled into a proper snapshot yet, you can use
restic recover and restore from the created snapshot(s).
Thanks for answer.
Have a good weekend!
Also the snapshot ID will change if tags are modified.