Skip to main content

Overview

A retention policy declares which snapshots to keep and which to remove based on age and recency. Ironcore Backup Solution (IBS) applies the policy during scheduled prune runs. The standard compliance pattern across the platform is 7-day daily + 3-week weekly at the Primary DC, with 52-week weekly archival at the Backup site. This page covers the retention syntax, policy placement (job vs. datastore), the Prune Simulator, and how to roll out a new policy safely.
Prerequisites
  • Administrator role on the Polystack platform
  • At least one datastore provisioned
  • At least one backup group with existing snapshots (to preview policy impact)

Compliance Retention Pattern

The pattern below satisfies the standard infrastructure retention model. Apply it consistently across all production workloads.
LayerPolicyTargetPurpose
Dailykeep-daily=7Primary DC datastoreRecover any day in the past week
Weeklykeep-weekly=3Primary DC datastoreRecover a stable weekly snapshot for the past 3 weeks
Weekly Archivalkeep-weekly=52Backup site datastoreLong-term archival and offsite disaster recovery

Retention Window Reference

WindowBehaviour
keep-last=NKeep the N most recent snapshots regardless of age
keep-hourly=NKeep the most recent snapshot for each of the last N hours
keep-daily=NKeep the most recent snapshot for each of the last N days
keep-weekly=NKeep the most recent snapshot for each of the last N weeks
keep-monthly=NKeep the most recent snapshot for each of the last N months
keep-yearly=NKeep the most recent snapshot for each of the last N years
Windows can be combined. A snapshot kept by any matching window is retained. For example, with keep-daily=7, keep-weekly=4, keep-monthly=12:
  • The 7 most recent daily snapshots are kept
  • Plus the most recent snapshot in each of the last 4 weeks
  • Plus the most recent snapshot in each of the last 12 months
A single snapshot may satisfy multiple windows simultaneously — for example, a Sunday backup may count as the day, the week, and the month.

Policy Placement

A retention policy can be attached at three levels:
LevelScopeWhen to Use
Backup jobAll snapshots created by that jobMost common — keeps policy with the workload
DatastoreDefault for all groups in the datastorePlatform-wide minimums
NamespaceAll groups in that namespacePer-team or per-environment overrides
Policies cascade with most-specific wins: job-level overrides namespace, which overrides datastore.
Configure a conservative platform-wide retention at the datastore level (for example, keep-last=2) as a safety net. Then let individual jobs declare their own retention.

Configure a Job Retention Policy

Open the job

Navigate to Backup Solution > Jobs and open the job.

Open Retention

Scroll to the Retention section.

Define windows

Enter the retention windows — for example:
  • keep-daily = 7
  • keep-weekly = 3

Preview the impact

Click Prune Simulator. The Simulator lists which existing snapshots would be removed and which retained, without making any changes.

Save

Click Save.
The new policy is applied on the next prune run for this job’s group.

Configure a Datastore-Level Policy

A datastore-level policy is the default for any group that does not declare its own retention.
Open the datastore detail page. The Default Retention field accepts the same windows as job-level retention. Save to apply.

Prune Simulator

The Prune Simulator computes the effect of a retention policy without modifying any data. Use it before any policy change to confirm the result matches your intent.
Simulate a policy change
ironcore-backup prune simulate \
  --repository ibs-primary \
  --namespace production \
  --backup-id vm/12345 \
  --retention "keep-daily=7,keep-weekly=3,keep-monthly=12"
Output:
Group: vm/12345
Snapshots: 92
Kept: 22
Removed: 70

Kept snapshots:
  2026-05-21T02:00:00Z   keep-daily   keep-weekly   keep-monthly
  2026-05-20T02:00:00Z   keep-daily
  2026-05-19T02:00:00Z   keep-daily
  ...
Always run the Prune Simulator before applying a more aggressive policy. Reducing a retention window does not undo the deletion that follows — only the manifests are removed, but chunk garbage collection makes the data unrecoverable shortly after.

Prune Schedule

Prune jobs run on the datastore schedule (default: daily 05:00). Adjust as needed:
Open the datastore. Set Prune Schedule under Scheduled Tasks.
After a prune removes a snapshot manifest, the underlying chunks are not immediately reclaimed. The Garbage Collector reclaims them on the GC schedule (default: weekly) — see Datastores.

Compliance Hold

To prevent specific snapshots from being pruned regardless of retention policy, apply a Compliance Hold. Held snapshots are excluded from prune runs until the hold is removed.
Open the snapshot. Click Apply Hold. Enter a reason and the responsible user / case number.

Troubleshooting

Confirm the active policy and check whether a more permissive policy is cascading from the namespace or datastore level. Run the Prune Simulator to identify the effective policy.
Prune only removes the snapshot manifest. The underlying chunks are reclaimed at the next Garbage Collection run. Check the GC schedule and last GC task result.
A more aggressive retention is permanent once GC runs. If GC has not yet run, restoring the policy and re-running prune may bring back some snapshots. Otherwise, restore from the Backup site replica.
Confirm the hold is active and not yet expired. Holds are also listed in the snapshot detail panel and in the audit log.

Next Steps

Datastores

Datastore provisioning and scheduled tasks

Replication and Sync

Replicate the weekly archival window to the Backup site

Verification and Validation

Verify retained snapshots and run bi-annual mock drills

Backup Jobs

Operator view of backup jobs and retention