I make backup copies at irregular periods and I want to keep them following the policy:
keep the last two
keep daily snapshots for the last week
keep weekly for the last month
keep monthly for the last year
keep yearly for the last 2 years
I understand that I would have to execute the following command:
restic -r /“BACKUP LOCATION” forget --keep-last 2 --keep-within-daily 7d --keep-within-weekly 1m --keep-within-monthly 1y --keep-within-yearly 2y
But restic shows the following:
unknown flag: --keep-within-daily
unknown flag: --keep-within-weekly
unknown flag: --keep-within-monthly
unknown flag: --keep-within-yearly
Do these parameters no longer exist?
How can I implement the conservation policy I want?
I have followed what is in the documentation:
“You might want to maintain the same policy as in the example above, but have irregular backups. For example, the 7 snapshots specified with --keep-daily 7 might be spread over a longer period. If what you want is to keep daily snapshots for the last week, weekly for the last month, monthly for the last year and yearly for the last 75 years, you can instead specify forget --keep-within-daily 7d --keep- within-weekly 1m --keep-within-monthly 1y --keep-within-yearly 75y (note that 1w is not a recognized duration, so you will have to specify 7d instead).”
I think you forgot restic command
restic -r /“BACKUP LOCATION” forget --keep-last 2 --keep-within-daily 7d ...
Forget to put forget in the message not in the command. Corrected the post
And what is your restic version?
restic 0.9.6 compiled with go1.12.12 on linux/amd64.
I installed it with Linux Software Manager Min 20.3
This is ancient restic version from 2019…
You have two options:
Use documentation and features available for your restic version -
Restic Documentation — restic 0.9.6 documentation
Update your restic to the latest version v0.16 and enjoy all features like
Thanks, I updated to the latest version
sudo restic self-update
Do I have a problem if the old copies were created with version 0.9.6 and the new ones with version 0.16?
Nope. All should work without any issues.
You might consider upgrading repository format - it will allow you to use data compression.
Have a look at this thread:
@thiscantbeserious You are saying that I could have done the migration and repacking on a copy of the repo? I didn’t consider that. But sure, that would work. Then simply move the whole thing to the desired end location afterward.
More details in docs -
Working with repositories — restic 0.16.0 documentation
I want something simple, this is complicated and I don’t understand English well .
I have to execute:
Can you confirm?
One last question and sorry for the inconvenience.
Could you help me in this thread?
When I restore a snapshot the computer cannot be used, it is very very slow, I do not think it is a problem with the CPU since it is a fast computer, nor with the 16 GB RAM, I think it is due to the disk writing speed that saturates it