Database Restore
The sections below detail how a database restore can be performed. Refer to the KurrentDB API for detailed information.
Prerequisites
Tips
To get the best out of this guide, a basic understanding of Kubernetes concepts is essential.
Before installing and executing the Operator, the following requirements should be met:
- The Operator has been installed as per the Installation section.
- A KurrentDBhas already been backed up.
- The following CLI tools are installed and configured to interact with your Kubernetes cluster. This means the tool must be accessible from your shell's $PATH, and your$KUBECONFIGenvironment variable must point to the correct Kubernetes configuration file:
Important
With the examples listed in this guide, the Operator is assumed to have been deployed such that it can track the kurrent namespace for deployments.
Restoring from a backup
A KurrentDB cluster can be restored from a backup by specifying an additional field sourceBackup as part of the cluster definition.
For example, if an existing KurrentDBBackup exists called kurrentdb-cluster-backup, the following snippet could be used to restore it:
apiVersion: kubernetes.kurrent.io/v1
kind: KurrentDB
metadata:
  name: kurrentdb-cluster
  namespace: kurrent
spec:
  replicas: 1
  image: docker.kurrent.io/kurrent-latest/kurrentdb:25.0.0
  sourceBackup: kurrentdb-cluster-backup
  resources:
    requests:
      cpu: 1000m
      memory: 1Gi
  network:
    domain: kurrentdb-cluster.kurrent.test
    loadBalancer:
      enabled: true