Challenge ·Medium

Back Up the Rancher Management State

Protect a Rancher installation against disaster. The Rancher Backup operator and a ResourceSet are already in place - create a Backup and confirm the operator produces a completed archive of the management state, the first step of any real recovery plan.

A Rancher installation is the map of everything it manages: cluster registrations, users, role bindings, catalogs, and Fleet definitions. If that state is lost, you lose the connection to every downstream cluster even if the clusters themselves survive. Protecting it is the foundation of disaster recovery.

The Rancher Backup operator is already installed on this cluster, along with a rancher-resource-set ResourceSet that defines which resources belong in a backup. You work from the dev-machine workstation, which has kubectl configured against the cluster. Your job: create a backup and confirm the operator produces a completed archive.

Create a Completed Backup

Request a one-time backup that uses the rancher-resource-set ResourceSet, then wait for the operator to finish writing the archive.

Hint 1 - the Backup object

The operator watches for Backup objects in the resources.cattle.io/v1 API. A Backup needs one thing in its spec: the name of the ResourceSet to use, which is already present as rancher-resource-set. Create the object with kubectl apply.

Hint 2 - confirming completion

The operator records progress on the Backup object. Check its Ready condition and its filename field with kubectl get backup <name> -o yaml. When the condition is True and a filename is set, the archive has been written. If it stays at Unknown, look at kubectl -n cattle-resources-system logs deploy/rancher-backup.