Restoring a Cloud Pak for Data backup on the target cluster with IBM Storage Fusion for testing purposes

After the target cluster is prepared, restore a Cloud Pak for Data backup on that cluster.

Before you begin

Create an online backup of Cloud Pak for Data.

About this task

Restore Cloud Pak for Data to a different cluster for testing purposes to ensure that you can successfully restore a Cloud Pak for Data backup to another cluster if the source cluster is lost.

In IBM Storage Fusion 2.5.2, you can only use the backup and restore (legacy) service to create backups. For more information about this service, see Backup and Restore (Legacy).

Procedure

  1. In IBM Spectrum® Protect Plus on the source cluster, create a restore job to restore the Cloud Pak for Data operators.
    1. Go to Jobs and Operations > Create Job.
    2. Select Restore.
    3. Select Containers > OpenShift.
    4. For the source, select the cluster where the backup was made, and then select the application to restore.
      Important: Select only one application to restore at a time. Do not select applications that end with :resources.
    5. For the source snapshot, select From Copy and On-Demand, and then select the restore point.
    6. For the destination, select Restore to alternate cluster, and then select the target cluster.
      Tip: If you do not see the target cluster, check if the reregistration of the remote BaaS agent was successful when you prepared the target cluster.
    7. Select Original Storage Class and Original Namespace.

      The restore must use the original namespace. The restore does not work if you select a different namespace.

    8. For job options, keep the default options.
    9. Submit the job.
      Note: If Cloud Pak for Data operator install plans in the source cluster are set to the manual approval strategy (installPlanApproval: Manual), you must approve the install plans as the operators are restored. Otherwise, the restore process will not progress. For more information about operator install plans, see Install plan.
      This job restores all required catalog sources, subscriptions, csvs, operandrequests, deployments for the Cloud Pak for Data operators and IBM Cloud Pak® foundational services.
  2. Repeat step 1 to restore the Cloud Pak for Data instance.
    This job redeploys the Cloud Pak for Data platform and all services.
  3. Specialized installations only: After Cloud Pak for Data operators and the Cloud Pak for Data instance are successfully restored, in the project where the IBM Cloud Pak for Data platform operator and service operators are installed, add the Cloud Pak for Data instance project to the nss-cpd-operators NamespaceScope resource:
    1. Edit the nss-cpd-operators NamespaceScope resource.
      For example,
      oc edit nss nss-cpd-operators -n ${PROJECT_CPD_OPS}
    2. In the namespaceMembers list, add the Cloud Pak for Data instance project.
      apiVersion: operator.ibm.com/v1
      kind: NamespaceScope
      metadata:
        annotations:
        name: nss-cpd-operators
        namespace: cpd-operators        # (Default) Replace with the Cloud Pak for Data platform operator project name
      spec:
        csvInjector:
          enable: true
        namespaceMembers:
        - cpd-operators                 # (Default) Replace with the Cloud Pak for Data platform operator project name
        - cpd-instance                  # Replace with the project where you are restoring Cloud Pak for Data
    When completed, Cloud Pak for Data operators begin reconciling custom resources in the Cloud Pak for Data instance project.

Results

Cloud Pak for Data is restored on the target (passive) cluster. You can use the target cluster as a standby cluster. If the source cluster is lost, you can switch to the target cluster, making the target cluster the active cluster.

CAUTION:
Because the target cluster is passive, do not perform any write operations on it. Otherwise, if your Cloud Pak for Data deployment has services that connect to an external database, both the active (source) and passive (target) clusters will write to the external database, which can cause data inconsistencies.

What to do next

When the IBM Spectrum Protect Plus restore job has completed, all resources are restored. However, the Cloud Pak for Data platform and services might need more time for the services to reconcile and start up before you can start using them. In Cloud Pak for Data, check that all service instances are restored and in good status.
  1. Run the cpd-cli manage login-to-ocp command to log in to the cluster as a user with sufficient permissions to complete this task. For example:
    cpd-cli manage login-to-ocp \
    --username=${OCP_USERNAME} \
    --password=${OCP_PASSWORD} \
    --server=${OCP_URL}
  2. Get the status of all services.
    cpd-cli manage get-cr-status \
    --cpd_instance_ns=${PROJECT_CPD_INSTANCE}
  3. Verify that all services show Completed.