Versioning

Versioning in Object Storage (also called bucket versioning, object versioning, and Amazon S3 versioning) is a method of retaining historical versions of objects. When you enable this feature, objects aren't overwritten or deleted. Instead, the new current version of an object is stored alongside each older noncurrent version. If you need to recover old data, you can restore or retrieve previous versions of each object.

Versioning automatically assigns a version ID to each object, when yu upload a new version. When you view or retrieve an object, the latest version is returned, unless you specify a version ID in the request. If you delete an object with bucket versioning enabled, a delete marker is inserted into the bucket to report that the object has been deleted, but the bucket will retain all previous versions of the object.

🚧

  • Every version of an object counts towards your monthly billable Object Storage quota. While you shouldn't worry about saving a few revisions, if you have large version-controlled buckets with many thousands of objects, you'll see a noticeable increase in storage space demands, and you should monitor them carefully.

  • While versioning is natively supported in Object Storage, none of our first-party tooling (such as Cloud Manager, the Linode CLI, or the Linode API) can manage this feature. Currently, object versioning can only be enabled, disabled, and otherwise managed through third-party tools.

Enable versioning

You enable versioning at the bucket level. This means that every object in a bucket will be versioned, not just a single object.

  1. See Use Cyberduck with Object Storage for installation instructions and connecting to Object Storage to view your buckets.

  2. Right-click on the desired bucket and select Info.

  3. Select the S3 tab.

    A screenshot of the S3 tab within the Info menu.

  4. Locate the Versioning section and check the Bucket Versioning checkbox to enable it.

A screenshot of the Versioning section showing the checked Bucket Versioning option.

Test versioning

Here's a simple way to test this feature, by uploading an example file and then replacing it.

  1. Create a text file, called something like example-file.txt on your local system that contains this text:

    This is version 1.
  2. Now, upload that file through any tool you want, including Cloud Manager, Cyberduck, s3cmd, or the AWS CLI.

  3. On your local machine, edit that same text file. In our example, we'll edit it to use the following contents:

    This is version 2.
  4. Upload the text file again to the same location that you used for the previous upload.

📘

Depending on the tool you're using, you may receive a warning that the file will be overwritten. Since versioning is enabled, previous versions will be retained. So, it's OK to continue.

View versioned objects

You can easily view your versioned objects using these tools:

  1. Open the View menu.
  2. Select Show Hidden Files. The previous versions of an object are displayed in gray.
  3. Select Refresh if previous versions don't automatically appear.

A screenshot of the files list.

Download and restore a previous version

Here's how to accomplish this using various tools:

To download a previous version, right-click on the version you want to save and select Download. Alternatively, you can drag and drop the file to your desktop or file explorer/Finder window.

To restore that version of the file, re-upload it. Another method is to delete all newer versions of the file.


Did this page help you?