Restoring from a Safeguarded backup

If your production data is compromised by a cyberattack, you can restore data to the source volumes with a Safeguarded backup. The IBM Copy Services Manager automates and simplifies that process of testing and restoring compromised data from a Safeguarded backup.

Before you can restore data to the source volume with a Safeguarded backup, ensure that you fully test the Safeguarded backups that are associated with the compromised source volume. Multiple versions of Safeguarded backups can exist and some versions can include ransomware or damaged data. The restore operation copies all source volume data with the version of the Safeguarded backup that you are restoring from. If you detect a breach, ensure that you test all the current Safeguarded backups that are associated with a source volume. By testing the backups, you ensure that you are restoring an uncompromised version of the Safeguarded backup to the source volume. For more information, see Recovering a Safeguarded backup.

Prerequisites for HyperSwap volumes

If the Safeguarded source volume is also a HyperSwap volume, you need to complete prerequisite tasks before you can use IBM Copy Services Manager to restore the HyperSwap source volume. The procedures depend on which HyperSwap site the Safeguarded Copy function is configured.

A best practice is to configure Safeguarded Copy function on the master site in the HyperSwap configuration. Configuring Safeguarded Copy function on the master site of a HyperSwap configuration simplifies the restore process to the same source volumes. Similarly, you can create Safeguarded backup on the auxiliary site and not the master site, but this use case has more considerations and steps. Use the following instructions before you restore a HyperSwap source volume:
Master site contains Safeguarded backups, and the auxiliary site does not.
In this use case, the master site in the HyperSwap system contains the HyperSwap source volumes with Safeguarded backups. Complete these steps before you restore the Safeguarded backup to the HyperSwap master volume:
  1. To verify the HyperSwap volume copies on the HyperSwap system, enter the following command:
    lsvdisk
    In the results that display, determine both the master site copy of the HyperSwap volume and the auxiliary site copy of the HyperSwap volume. In the results, gather the following information:
    • Use the results in the function field to determine whether the volume copy is on the auxiliary site in the HyperSwap relationship. The value aux indicates the volume copy at the auxiliary site.
    • Determine the pool name or ID that is used by the volume copy on the auxiliary site.
    • Determine the ID of the volume copy on the auxiliary site.
    • Determine the name or the ID of the volume on which the copies are based.
  2. To remove the volume copy that was identified in step 1, enter the following command:
    svctask rmvolumecopy -copy <copy_id> -pool <pool_id_or_name> -removefcmaps <name_id> 
    where <copy_id> indicates the copy identifier for the copy on the auxiliary site; <pool_id_or_name> indicates the name or identifier of the pool, and <name_id> indicates the name or ID of the volume that is associated with the copy. This command removes the volume copy at the auxiliary site, its associated FlashCopy mappings, and change volumes that are created when HyperSwap volume was created. This action makes the volume copy at the master site an independent volume that can be recovered with IBM Copy Services Manager.
Auxiliary site contains Safeguarded backups, and the master site does not.
In this use case the auxiliary site in the HyperSwap system contains the HyperSwap source volumes with Safeguarded backups. Complete these steps before you restore the Safeguarded backup to the HyperSwap auxiliary volume:
  1. To verify the HyperSwap volume copies on the HyperSwap system, enter the following command:
    lsvdisk
    In the results that display, determine both the master site copy of the HyperSwap volume and the auxiliary site copy of the HyperSwap volume. In the results, gather the following information:
    • Use the results in the function field to determine whether the volume copy is on the master site in the HyperSwap relationship. The value master indicates the volume copy at the master site in HyperSwap configuration.
    • Determine the pool name or ID that is used by the volume copy on the master site.
    • Determine the ID of the volume copy on the master site.
    • Determine the name or the ID of the volume on which the copies are based.
  2. To remove the volume copy that was identified in step 1, enter the following command:
    svctask rmvolumecopy -copy <copy_id> -pool <pool_id_or_name> -removefcmaps <name_id> 
    where <copy_id> indicates the copy identifier for the copy on the master site; <pool_id_or_name> indicates the name or identifier of the pool, and <name_id> indicates the name or ID of the volume that is associated with the copy. This command removes the volume copy at the master site, its associated FlashCopy mappings, and change volumes that are created when HyperSwap volume was created. This action makes the volume copy at the auxiliary site an independent volume that can be recovered with IBM Copy Services Manager.
Both sites contain Safeguarded backups, but you are restoring the backup to the master site
If both sites contain Safeguarded backups, but you want to restore to the master site only, complete the following steps:
  1. To verify the HyperSwap volume copies on the HyperSwap system, enter the following command:
    lsvdisk
    In the results that display, determine both the master site copy of the HyperSwap volume and the auxiliary site copy of the HyperSwap volume. In the results, gather the following information:
    • Use the results in the function field to determine whether the volume copy is on the auxiliary site in the HyperSwap relationship. The value aux indicates the volume copy at the auxiliary site in HyperSwap configuration.
    • Determine the pool name or ID that is used by the volume copy at the auxiliary site.
    • Determine the ID of the volume copy on the auxiliary site.
    • Determine the name or the ID of the volume that the copies are based on.
  2. To remove the volume copy that was identified in step 1, enter the following command:
    svctask rmvolumecopy -copy <copy_id> -pool <pool_id_or_name> -removefcmaps <name_id> 
    where <copy_id> indicates the copy identifier for the copy on the auxiliary site; <pool_id_or_name> indicates the name or identifier of the pool, and <name_id> indicates the name or ID of the volume that is associated with the copy. This command removes the volume copy at the auxiliary site, its associated FlashCopy mappings, and change volumes that are created when HyperSwap volume was created. This action makes the volume copy at the master site an independent volume that can be recovered with IBM Copy Services Manager.

Restoring Safeguarded backups with IBM Copy Services Manager

To recover Safeguarded backups, complete these steps:
  1. Log in to https://<IP address or domain name>:9559/CSM where <IP address or domain name> is the IP address or domain name of IBM Copy Services Manager instance. Use the Administrator user name and password that you created during the configuration of Safeguarded Copy function.
  2. On the Sessions Overview page, select Sessions.
  3. On the Sessions page, select the volume group that contains Safeguarded backup copies that you want to restore.
  4. Select Session Actions > Command > Restore Backup.
  5. On the Restore Backup page, select the version of the Safeguarded backup that you want to restore. Safeguarded backups are displayed by their backup time from the most recent to the latest version. Restored Safeguarded backups replace the source volumes that is currently defined in volume group. Click Yes.
  6. Ensure that the restore operation completes successfully. After the copy is restored to the source volume, the session state displays Target Available. You can also monitor the progress of the restore action by selecting Console to display all the command operations that were run during the action.
  7. If you restored a HyperSwap source volume, you must return the recovered source volume to a HyperSwap volume with the addvolumecopy command. Enter the following command to create a copy of the restored volume on the other site:
    addvolumecopy -pool <storage_pool_id or storage_pool_name> <volume_name or volume_id>
    where <storage_pool_id or storage_pool_name> is the pool that is located on the other site and <volume_name or volume_id> is the name of the volume that was restored.