Cloudflare R2 alternative when you need S3 versioning and Object Lock

If your backup tools or retention rules expect S3 versioning and Object Lock, R2's S3 API does not provide them. Ceph RGW is the self-hosted option with versioned buckets, retention modes and legal holds.

On this page

Cloudflare R2 alternative when you need S3 versioning and Object Lock: the short answer

If a backup tool or a retention rule expects S3 versioning and Object Lock, R2 is likely to fail that check, because R2's S3 API does not implement either feature. The self-hosted option that covers this requirement from the supplied facts is Ceph RADOS Gateway (RGW). Ceph RGW supports versioned buckets, and Object Lock on top of them provides governance and compliance retention modes along with legal holds. Those are the three controls a retention rule usually names, so Ceph is the starting point for a like-for-like replacement.

Garage and SeaweedFS do not give you the same guarantees. Garage's S3 compatibility reference states that it does not support object versioning, object locking or server-side encryption, so it cannot satisfy a rule that depends on either feature. For SeaweedFS, the supplied facts describe its S3 support and erasure coding but do not establish versioning or Object Lock behavior, so confirm that directly against its current documentation and your backup tool's requirements before choosing it.

Do not assume R2 bucket locks are the same thing as S3 Object Lock. Bucket locks are a separate Cloudflare mechanism, so read the retention rule and the backup tool's documentation to see which exact behavior it needs, including whether it requires per-object retention modes, legal holds or version history. Confirm the requirement with the tool vendor and the auditor or compliance owner who wrote the rule, then test a restore and a retention-blocked delete on Ceph in your own environment before you commit.

What versioning and Object Lock requirements impose on storage

Backup tools and regulators check retention in specific ways: whether old versions survive, whether deletes are blocked, and whether a copy is isolated from the production account. Each card below is a requirement your storage must meet before a Cloudflare R2 replacement can satisfy the same checks.

Write-once-read-many behavior

Write-once-read-many means an object cannot be changed or deleted for a set period once it is locked. Amazon describes S3 Object Lock as this model, and it is the property auditors ask about first when they review immutable backups. Before you move, confirm with your backup tool whether it writes locked objects, and test that a delete attempt inside the retention window is refused by the storage layer, not only by the backup software.

Object Lock docs

Versioned buckets as a prerequisite

Object Lock only works in versioned buckets, so versioning is the foundation for every retention control above it. Your backup tool may depend on version IDs to restore an earlier state after ransomware encrypts objects. R2's S3 API does not implement versioning, so a Ceph RGW bucket must have versioning enabled before lock settings can be applied. Ask your backup vendor which versioning behavior it expects on restore.

Governance versus compliance retention

Governance retention lets users with a specific bypass permission shorten or remove a lock, while compliance retention cannot be shortened or removed by any user until it expires. Choose the mode from your written policy and regulator guidance, not from convenience. Confirm who holds the bypass permission in a self-hosted setup, since that account becomes the weak point an auditor will test.

Legal holds

A legal hold keeps an object locked for as long as it is set, independent of any retention period, and is removed only by an explicit action. Litigation and investigations usually require holds on specific objects rather than whole buckets. Check that your storage supports holds separately from retention, and that someone in legal or compliance can set and clear them with an audit trail that records who did it.

Isolated recovery copy

CIS Control 11.4 asks for an isolated instance of recovery data, with offline, cloud, or off-site version-controlled backups given as examples. A locked copy in the same cluster and under the same administrator credentials may not meet that intent. Define where the isolated copy lives, which identities can reach it, and how you prove it survives a compromise of the production environment.

Control 11 specification

What R2 bucket locks do instead of S3 Object Lock

R2's S3 API does not implement S3 versioning or Object Lock, so a backup tool or retention rule that calls those APIs will not get the write-once-read-many behavior it expects. In Amazon S3, Object Lock works only in versioned buckets and offers governance and compliance retention modes plus legal holds, as described in the Amazon S3 user guide on Object Lock. Cloudflare offers R2 bucket locks as its own mechanism. Treat them as a different feature until you have checked Cloudflare's current documentation for which operations the lock blocks, how long it lasts, whether an account administrator can shorten or remove it, and whether it covers every object in a bucket or only matching prefixes.

Before you rely on R2 bucket locks for retention, run a restore and deletion test with the exact backup software you use. Confirm how it behaves when a delete or overwrite is refused, whether it treats the lock as an error, retries endlessly, or skips the object silently, and whether it reads retention status through any S3 Object Lock call such as GetObjectRetention or the x-amz-object-lock-mode header. Ask Cloudflare in writing whether those calls are supported. If your policy requires a specific retention mode or legal hold, map each requirement to a documented R2 behavior and record the gaps, because a bucket lock that resembles retention on a slide may not satisfy an auditor's reading of your policy.

On a self-hosted Ceph RADOS Gateway, versioning is documented, along with lifecycle rules and bucket policies, so you can keep prior object versions in the same cluster. Confirm which Object Lock behaviors your Ceph release implements before planning around governance retention, compliance retention or legal holds, and test them with your backup tool. Garage does not support versioning or Object Lock, so it cannot cover this requirement. Whatever you choose, a retention lock on one cluster does not by itself meet the isolated recovery copy described in CIS Control 11, Safeguard 11.4, which calls for an off-site, offline or separately controlled backup destination. Plan that copy as its own decision.

Which self-hosted stores meet versioning and Object Lock needs

This table compares Ceph RGW, SeaweedFS and Garage on the features that backup tools and retention rules usually expect from S3. Read each row as a question to put to the vendor or to your own test cluster, since a documented feature still needs to be verified against the retention behavior your policies require. The main takeaway is that Ceph RGW is the only option here with documented versioning and bucket policies, while Garage cannot meet a versioning or Object Lock requirement and SeaweedFS Object Lock support needs confirmation before you commit.

CapabilityCeph RGWSeaweedFSGarage
S3 versioningDocumented support for versioned bucketsConfirm versioning behavior in the S3 gateway for your releaseNot supported
Object Lock with governance and compliance modesDocumented in the Ceph S3 API reference; test both modes against your backup tool before relying on themConfirm support in your release; do not assume parity with AWS S3 Object LockNot supported
Legal holdsConfirm legal hold behavior on your Ceph release and test it end to endConfirm before adopting; not documented in the supplied materialNot supported
Bucket policies and ACLsDocumented support for bothConfirm the policy and ACL scope in the S3 gatewayNot documented as a full feature set; confirm before use
Lifecycle rulesDocumented supportConfirm against your retention and expiry rulesNot documented as supported in the reference
ReplicationBucket replication across zones only; plan multisite design earlyConfirm replication model and failure domains for your layoutGeo-distributed cluster design rather than bucket-level replication controls
LicenseLGPL-2.1 or LGPL-3 for the Ceph source, with some bundled components under other licensesApache-2.0 for the open-source project, with a paid Enterprise EditionAGPL-3.0
Maintenance statusActively maintained releases with backports and security fixes; check the current release tableActively developed; confirm the release and support model you plan to useConfirm current release status before selecting

How Ceph RGW provides versioned buckets and retention holds

In Ceph RGW, a versioned bucket keeps every prior version of an object when it is overwritten, and a delete adds a delete marker and leaves the earlier versions in place. Versioning is the prerequisite for Object Lock, so the first check is that the bucket, the RGW user and your backup client all make the same versioning calls. Before relying on this for retention, confirm in the Ceph S3 API reference which bucket versioning, Object Lock configuration, object retention and legal hold operations your release implements, and whether they behave the way the Amazon S3 model describes. Record the release you tested, such as a Tentacle (20.2.x) or Squid (19.2.x) build, and repeat the test after every upgrade.

Object Lock then sets how long each object version stays protected. Governance mode blocks changes and deletions for most principals, but users with the bypass permission can remove data during an incident. In the S3 model, compliance mode prevents anyone, including administrators, from shortening or removing the retain-until date until it passes, and you should verify that RGW enforces this exactly. A legal hold is independent of both modes: it blocks deletion of a specific version with no end date and stays in force until someone removes it explicitly. Decide who holds the bypass permission, who may place or lift holds, and whether a default retention applies to new objects. Then test each mode on a throwaway bucket, because enforcement details are where backup tools most often fail.

How to deploy Ceph RGW with versioning and Object Lock enabled

This sequence takes a team from retention requirements to a tested Ceph Object Gateway where versioned buckets, Object Lock retention and an isolated off-site copy behave the way the backup tool and the regulator expect before any production data moves.

  1. Confirm retention modes and legal hold needs

    Before touching hardware, the compliance lead and the backup tool owner agree in writing which retention mode each data class needs, whether governance or compliance, which objects need legal holds, and how long each class must be protected. Ask the backup vendor which S3 calls it issues, including versioning and Object Lock headers, and confirm whether it expects bucket-level default retention or per-object retention. Ask your regulator or auditor whether any environment needs a third-party assessment of the storage behavior, since AWS's Object Lock assessment does not transfer to your own Ceph deployment. Done when the requirements sheet names each bucket, mode, hold process and the tool calls it depends on.

  2. Choose a supported Ceph release

    Open the Ceph active releases page and select a release that is still in its maintained window. Record the release name, the latest point release and its estimated end of life, then set a calendar reminder for the upgrade decision before that date. Confirm with your platform team that the chosen release is supported by your operating system and container runtime. Done when the selected release, point version and end-of-life date are written into the design record and approved by the engineering owner.

  3. Bootstrap the cluster with cephadm

    On the first host, bootstrap a single-node cluster with cephadm, which starts one Monitor and one Manager in containers, then add the remaining hosts and deploy the Object Gateway service with a placement that matches your fault domains. If you run Kubernetes, the cephadm documentation points to Rook as the alternative deployment path, so make that choice before this step. Enable the Dashboard only after you decide how operators will sign in. Done when ceph -s reports a healthy cluster with the expected monitors, managers and RGW daemons running.

  4. Size OSDs and metadata against hardware guidance

    Follow the Ceph hardware recommendations when you choose drives: one dedicated drive per OSD, WAL and DB on shared enterprise SSDs for HDD-based OSDs, and bonded network links across two switches. Size memory for peak load rather than average load, and benchmark a representative workload before you buy, because the guidance notes that no two clusters are alike. Ask your hardware vendor to quote these components separately so that replacement drives and SSD endurance are visible in the budget. Done when the bill of materials and a benchmark result show that the chosen layout meets your ingest and restore targets.

  5. Enable versioning and Object Lock on buckets

    Create each bucket with Object Lock enabled, because Ceph requires the lock configuration to be set when the bucket is created and Object Lock works only in versioned buckets. Confirm that versioning is active on the bucket, then apply the default retention rule that matches the requirements sheet. Create a dedicated RGW user for the backup tool with only the bucket permissions it needs, and record the access key in your secrets manager. Done when a test object written with the backup tool shows a version ID and retention metadata when you query it with an S3 client.

  6. Configure retention and legal holds

    Apply retention periods and legal holds through the S3 API or your backup tool, matching the modes agreed in step one. Verify that governance retention can be bypassed only by a principal with the bypass permission, and that compliance retention cannot be shortened or removed before it expires. Document who may place or release a legal hold and how the release is logged. Done when a deliberate delete attempt against a protected version is refused, a legal hold blocks deletion after the retention period ends, and the test results are saved with the design record.

  7. Set up an isolated off-site copy

    Configure a second copy of the recovery data in a location that the primary cluster's administrators cannot change directly, such as a separate cluster, another site or offline media. Ceph's bucket replication works only across zones within a multisite design, so confirm the replication path your topology supports and whether it preserves lock settings. The CIS Controls v8.1 Safeguard 11.4 describes an isolated recovery data instance with offline, cloud or off-site version-controlled destinations as examples; check the control text in the assessment specification and map your design to it. Done when the off-site copy holds versioned objects with lock state confirmed and access limited to a separate credential set.

  8. Test restore and retention before cutover

    Run a restore drill from the isolated copy into a clean environment, including a version rollback and a restore of an object under legal hold. Attempt to delete protected objects with normal and administrative credentials and record each refusal. Time the restore against your recovery objective and record the results. Only after the drill passes, switch the backup tool endpoint to the Ceph gateway and keep the previous destination read-only until the first full retention cycle is verified. Done when the signed drill report shows successful restores, enforced retention and a documented rollback path.

How versioned buckets, retention and the isolated copy fit together

The flow starts with a backup client writing to a versioned Ceph RGW bucket where Object Lock applies retention and legal holds to each object version. Ceph replicates the bucket to a second zone for recovery, which stays on the production side of the trust boundary. The isolated off-site copy sits outside that boundary, and it should receive its own credentials and retention settings. Check that no production administrator can delete or overwrite the isolated copy, and that restores have been tested from it.

Backup writes, retention locks and the isolated recovery copy, split by trust boundary.

Evidence auditors and regulators ask for under retention rules

Retention rules are judged on evidence, not on the storage product's claims. The five items below are the records an assessor will usually ask to see when backups or regulated records depend on versioned, locked objects. DeployOpen prepares this evidence, but auditors and certification bodies draw the conclusions.

Bucket configuration exports

Export the versioning state and Object Lock settings for every bucket that holds retained or backup data, and keep the exports dated and tied to the cluster. On Ceph RGW, confirm that versioning is enabled before any lock is applied, because Object Lock works only in versioned buckets. Ask the auditor which bucket attributes they want captured and how often, and store each export as a point-in-time record rather than a live view. Also record the bucket policies and users that can change these settings.

Ceph S3 API docs

Retention policy records

Write down which objects get governance retention, which get compliance retention, and how long each period runs. Governance mode lets users with the right permission override or remove a lock, while compliance mode does not allow shortening or removal before the period ends, so the choice must match the rule the business has to meet. Keep the approved policy, its owner and its change history together. Check that the bucket default and per-object settings agree with the written policy.

Legal hold logs

A legal hold keeps an object locked independently of its retention period, and it is removed only by an explicit action. Log every hold placed and released, with the requester, the object or prefix, the matter reference and the timestamps. Confirm who can place and remove holds, and whether that role is separate from the people who manage the buckets. An assessor will compare hold logs with the objects they protect, so missing entries are a common finding.

Restore test results

Retention shows that data is kept, but assessors also want proof that it can be recovered. Run restores from versioned or locked copies on a schedule, including restoring a previous version of an object and restoring a set of objects after a simulated deletion. Record the scope, the date, the time taken, the checksums compared and the people who signed off. Failed tests and the fixes that followed should stay in the record.

Documented isolation of recovery data

The CIS Controls v8.1 control on data recovery asks for an isolated instance of recovery data, with an offline, cloud or off-site copy that is version controlled. Document where the locked copy sits, which accounts and admin paths can reach it, and how it is separated from production credentials. Explain how that separation would hold if the primary cluster were compromised. Ask your auditor which control IDs your assessment uses, since the mapping depends on your scope.

CIS Control 11 spec

Questions teams ask before changing retention storage

What does it cost to move retention storage off R2 to Ceph?

The cost is mostly people time and recurring infrastructure, not a single line item. You pay for planning the bucket lock inventory, standing up the Ceph cluster, copying data, rebuilding retention rules as Object Lock settings, and validating the result. The recurring side is servers, drives, network, power, support and the staff who run the cluster. Costs rise with the number of buckets, the number of distinct retention policies, total data volume and how many backup tools must be repointed. Ask any quote to break out design, build, migration, retention testing, handover and ongoing support as separate items so you can see what is one-time and what recurs.

How long does validating retention rules take?

Validation time depends on data volume, the number of buckets and retention modes, and how many people are available to test. It also depends on whether your backup tools and auditors need evidence of each mode, not just a working bucket. Retention checks are slower than data checks because you must confirm that objects cannot be deleted or overwritten during the retention period, that legal holds block deletion independently of retention, and that the expected versions remain in place. Ask the implementation partner for a written test plan, the sample size they will verify, and who signs off each stage. No fixed duration is stated here because it varies with your environment.

What does the migration need from our internal staff?

Your staff must supply accurate knowledge of the systems that depend on the storage. In practice that means the owners of each backup tool, the compliance lead who defines retention periods, and the team that manages R2 API tokens and any Workers or public bucket paths. The people who approve retention changes must be available during the cutover, because Object Lock settings are difficult to relax once set. Expect your security team to review access control and key handling for the new cluster. Confirm with the implementation partner which of these tasks they will carry out and which must come from your team.

Can our internal team run Ceph object storage without outside help?

Yes, many teams can, but only if they have people with storage, networking and Linux operations experience and enough time to keep the cluster healthy. Ceph's hardware guidance calls for dedicated drives per OSD, SSDs for metadata, bonded network links across two switches and memory sized for peak use, so the operating burden is real. Your team must also handle upgrades, monitoring, capacity planning and recovery drills. Consider whether those skills can be kept in-house after handover. A fixed-scope engagement can cover build and documentation, while a retainer covers upgrades and continuous testing if you want outside help after go-live.

How do we verify that retention rules are enforced?

Verify retention with tests that try to break the rule and record what happens. Upload test objects to a versioned bucket, apply governance and compliance retention, then attempt deletion and overwrite with each credential type your backup tools use. Repeat the checks for legal holds, and confirm that the version history and retention metadata match your written policy. Keep the results as evidence for your internal audit or compliance assessment. DeployOpen prepares systems, controls and evidence for compliance assessments, but independent auditors and certification bodies issue any audit report or attestation.

Can SeaweedFS or Garage replace R2 for versioning and Object Lock?

Not for these requirements, based on the documented capabilities. Garage's compatibility reference states that it does not support object versioning, object locking or server-side encryption, so it cannot meet a retention rule that depends on those features. SeaweedFS is an S3-compatible store with a paid Enterprise Edition, and you should confirm with its project whether the open-source edition provides versioning and object lock behavior that your backup tools rely on before you choose it. If retention enforcement is required, Ceph RADOS Gateway is the option this page evaluates, because Ceph documents versioning and bucket policies. Confirm each feature in your own test environment before committing.

Does moving to Ceph change the durability I get from R2?

Durability depends on how you build the cluster, not on the S3 API alone. R2 and Ceph use different designs, and a self-hosted Ceph cluster inherits the failure domains, replication or erasure coding settings, and drive choices you make. Amazon S3 Standard is designed for 99.999999999% durability across at least three Availability Zones, which gives a reference point but not a direct comparison. Your retention design should also consider an isolated copy of recovery data, which the CIS Controls v8.1 Safeguard 11.4 describes in general terms as an isolated instance of recovery data. Ask your design partner how replicas, failure domains and off-site copies will be set up and tested.

What to confirm with your vendors and auditors before migrating

Before you move any locked data, confirm the exact retention mode names your backup tool and retention rules expect. Backup products often call for governance or compliance retention through their own settings, and the S3 API fields they send must map to Ceph RGW's Object Lock behavior. Ask the backup vendor in writing which request headers and bucket settings it sends, whether it requires Object Lock to be enabled at bucket creation, and how it reports a failed lock. Run a test restore and a test deletion attempt against a non-production bucket. Do not assume that a successful upload proves the retention rule is enforced.

Next, ask your regulator, internal audit, or external assessor whether the chosen design meets your obligations. Amazon's Object Lock documentation notes an independent assessment against SEC 17a-4, CFTC and FINRA environments, but that assessment applies to Amazon's service, not to a self-hosted Ceph cluster you operate. Present the design with the retention modes, who holds the credentials that could bypass governance retention, how legal holds are placed and released, and where audit logs are kept. Ask whether a compliance-mode lock on your own hardware meets the wording of your policy. Keep the answer in writing, because the assessor's view decides the design, not this page.

Then confirm how Object Lock behaves on existing R2 data. R2 does not implement S3 versioning or Object Lock, so objects copied across do not carry prior lock state, and any retention you need must be applied again on the target bucket after copying. Decide whether historical versions exist anywhere in your source, and document that the copy represents only current objects if that is the case. Finally, check the target release notes for SeaweedFS or Garage before relying on either for a related workload, because the facts available here describe current limits, and features can change in a target release. Confirm with each project and record the version you tested.

How DeployOpen deploys Ceph RGW under retention requirements

DeployOpen plans, implements, hardens, documents and supports self-hosted open-source platforms inside your own infrastructure, including Ceph RGW for teams that need versioned buckets and retention controls. For this move, we start from the retention rules your backup tools and compliance team actually depend on, then build and hand over a Ceph deployment your own teams can review.

How we scope

  • Inventory every backup tool, retention rule and bucket lock that expects S3 versioning or Object Lock today.
  • Record which retention modes, legal hold use and compliance evidence your auditors or regulators will ask to see.
  • Agree scope, deliverables and timelines in writing before work starts, since most engagements are fixed-scope.

How we build

  • Deploy Ceph RGW with versioned buckets, Object Lock settings and bucket policies matched to the scoped retention rules.
  • Configure SSO, access control and audit logging so the security and compliance teams can review who changed retention settings.
  • Test retention behavior, including that protected object versions cannot be deleted early, before any production data is moved.

How we hand over

  • Deliver runbooks covering bucket creation, retention configuration, legal hold procedures and backup restore steps.
  • Document the control mapping for CIS Controls v8.1 Safeguard 11.4 so your team can show an isolated recovery copy exists.
  • Provide a handover session and written evidence that prepares your environment for an independent assessment, which auditors and certification bodies perform.

How we support

  • Ongoing support, upgrades and continuous testing are available as retainers after handover.
  • Plan Ceph release upgrades against the active release schedule published by the Ceph project before each change window.
  • Retest retention behavior after upgrades, configuration changes or changes to backup tooling.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.