Azure Blob snapshot support


I just looked at the code for the Azure Blob storage backend and the used SDK. It seems the SDK allows the usage of Blob snapshots with a single command, but the backend has no reference to it.

It doesn't seem I'm able to pass any custom commands to the underlying SDK from the rclone CLI, so I cannot 'finish' a backup by creating a snapshot. Is this possible at all or do I actually need a 'feature request' to use snapshots?

Firstly note that I've just re-written the Azure blob SDK to use the new SDK! So don't send PRs on azureblob until I've merged that.

You are right, rclone doesn't support blob snapshots at the moment, though according to the docs, supporting versions might be better.

Other backends have support for versions, eg here is the s3 versions support.

Is that the kind of thing you are looking for? If so would your employer like to sponsor the feature?

It would be easy to make an rclone backend command to take a snapshot, but rclone wouldn't be able to read it currently.

You can add backend specific commands - azureblob doesn't have any right now, but if you want to see s3's for example, type rclone backend help s3

Ah, thanks for your reply.

Versions won't work, afaik, as I am trying to clone an entire interdependent directory structure at a specific point in time. So I would have just frozen it, cloned it and then, after the cloning was successful, created a snapshot:
That way the remote structure would always be coherent.

Sadly, it isn't for my employer. With custom commands I meant for example Graph API calls or something in the context of the rclone process, for example before or after the clone.

It looks easy to create a snapshot of a blob with the new SDK (which I've just merged).

An rclone backend command could be given a directory, iterate it to find all blobs and call the snapshot command on every blob.

Here is an example of an s3 backend command which restores blobs from glacier - the logic would be very similar

And the loop

So you could have a go at that to create the snapshot?

Ah, I switched to trying the recent SMB backend with Azure Storage. This enables policy-based snapshotting without any changes in rclone.

1 Like