Monday 20 Mar 2023
Restore previous versions (B2)
I was testing backup restores and was wondering: how to restore a delete file or previous version in my B2 storage. This is assuming you have enabled versioning on your B2 bucket.
As usual, rclone has us covered. My remotes are encrypted so I need rclone to view file names. Use the command:
rclone ls remote:dir/ --b2-versions
Or for more details
rclone lsl remote:dir/ --b2-versions
You will get an output of previous versions:
super-important-file-v2023-03-13-100755-166.bak super-important-file-v2023-03-10-193737-104.bak super-important-file-v2023-03-10-193257-296.bak super-important-file-v2023-03-08-080243-354.bak super-important-file-v2023-03-08-075833-207.bak super-important-file-v2023-03-08-075825-995.bak super-important-file-v2023-03-08-075727-966.bak
It was easy to copy the version I wanted:
rclone copy remote:dir/super-important-file-v2023-03-13-100755-166.bak -b2-version C:\Dir
Backlinks:
Journal:Index
Journal:2023:03