Recovering the server scenario

You can recover the server after a disaster. In this example virtual volumes are not used. The steps are completed by the onsite administrator unless otherwise indicated.

Procedure

Restriction: When you run the disaster recovery script or the commands that the script contains, you must determine whether to run as root or as the DB2® instance user ID.

  1. Review the recovery steps that are described in the RECOVERY.INSTRUCTIONS.GENERAL stanza of the plan.
  2. Request the server backup tapes from the offsite vault.
  3. Break out the recovery plan file stanzas into multiple file. These files can be viewed, updated, printed, or run as Tivoli® Storage Manager macros or scripts.
  4. Print the RECOVERY.VOLUMES.REQUIRED file. Give the printout to the courier to retrieve the copy storage pool volumes and active-data pool volumes.
  5. Find a replacement server. The RECOVERY.DEVICES.REQUIRED stanza specifies the device type that read the backups. The SERVER.REQUIREMENTS stanza specifies the disk space. Windows operating systems
    Note: When you use the Tivoli Storage Manager device driver (ADSMSCSI), you must start ADSMSCSI.
  6. The recovery media names and their locations are specified in the RECOVERY.INSTRUCTIONS.INSTALL stanza and the MACHINE.RECOVERY.MEDIA.REQUIRED stanza. Ensure that the environment is the same as when the disaster recovery plan file was created. The environment includes the following directory structures:
    • The directory structure of the executable Tivoli Storage Manager server file and disk formatting utility
    • The directory structure for Tivoli Storage Manager server configuration files (disk log, volume history file, device configuration file, and server options file)
    • The directory structure and the files that are created when the disaster recovery plan file was split into multiple files
  7. AIX operating systemsRestore the operating system and the Tivoli Storage Manager server software to the replacement server in one of the following ways:
    • Build a new replacement server instead of restoring the environment from a backup:
      1. Install the Tivoli Storage Manager server software
      2. Create the database instance user ID and group as in the original.
      3. Create the database directories, the active directories, and the archive directories as in the original.
      4. Run the dsmicfgx utility to configure the replacement instance. This step configures the API for the DSMSERV RESTORE DB utility.
        1. Specify the instance user ID and password.
        2. Specify the database directories, the active directories, and the archive directories.
      5. Remove the database instance that was created by the dsmicfgx utility. For example,
        dsmserv removedb TSMDB1
      6. Restore the original dsmserv.opt, volume history, and device configuration files to the instance directory (as done by the recovery script in plan file).
      7. Run the DSMSERV RESTORE DB utility (as done by the recovery script in the plan file).
    • Use a mksysb or Sysback tape. This tape, which includes the Tivoli Storage Manager server software, is created whenever software updates or configuration changes are made to the AIX® system. The tape location might be specified in the RECOVERY.INSTRUCTIONS.INSTALL stanza.
      Restoration from the mksysb tapes includes recreating the following items:
      • The root volume group
      • The file system where the database, active log, and archive log directories, and the storage pool and disk volumes are located
      After you use a mksysb or Sysback tape, issue the following commands:
      RUN DB2ILIST
      RUN DB2 LIST DB DIRECTORY
      Verify that the DB2 instance and database information are restored. Create any additional AIX file systems that might have contained directories that are needed by the Tivoli Storage Manager server. Create the directories and set the ownership and group to match the instance ownership. Verify the following file system directory types:
      • Archive
      • Active
      • Failover
      • Database
      You can find these directories by issuing the DB2 GET DB CFG SHOW DETAIL command and reviewing the output or looking in the recovery plan file.
  8. HP-UX operating systemsLinux operating systemsOracle Solaris operating systemsRestore the operating system and the Tivoli Storage Manager server software to the replacement server in one of the following ways:
    • Use a system restore utility that is appropriate for your operating system.
    • Build a new replacement server instead of restoring the environment from a backup:
      1. Install the Tivoli Storage Manager server software
      2. Create the database instance user ID and group as in the original.
      3. Create the database directories, the active directories, and the archive directories as in the original.
      4. Run the dsmicfgx utility to configure the replacement instance. This step configures the API for the DSMSERV RESTORE DB utility.
        1. Specify the instance userid and password.
        2. Specify the database directories, the active directories, and the archive directories.
      5. Remove the database instance that was created by the dsmicfgx utility. For example,
        dsmserv removedb TSMDB1
      6. Restore the original dsmserv.opt, volume history, and device configuration files to the instance directory (as done by the recovery script in plan file)
      7. Run the DSMSERV RESTORE DB (as done by the recovery script in the plan file.
  9. Windows operating systemsRestore the operating system, the Tivoli Storage Manager server software, the Tivoli Storage Manager licenses, and the administrative client on the replacement hardware.
    1. Build a new replacement server instead of restoring the environment from a backup:
      1. Install the Tivoli Storage Manager server software.
      2. Create the database directories, the active directories, and the archive directories as in the original.
      3. Run the dsmicfgx utility to configure the replacement instance. This step configures the API for the DSMSERV RESTORE DB utility.
        • Specify the instance userid and password.
        • Specify the database directories, the active directories, and the archive directories.
      4. Remove the database instance that was created by the dsmicfgx utility. For example,
        dsmserv removedb TSMDB1
      5. Restore the original dsmserv.opt, volume history, and device configuration files to the instance directory (as done by the recovery script in plan file)
      6. Run the DSMSERV RESTORE DB (as done by the recovery script in the plan file).
  10. Review the Tivoli Storage Manager macros that are contained in the recovery plan. If the following conditions are true at the time of the disaster, complete the following tasks:
    • The courier does not have the previous night's database and storage pool incremental backup volumes but they were not destroyed, remove the entry for the storage pool backup volumes from the COPYSTGPOOL.VOLUMES.DESTROYED file.
    • The courier does not have the previous night's database and active-data pool volumes but they were not destroyed, remove the entry for the active-data pool volumes from the ACTIVEDATASTGPOOL.VOLUMES.DESTROYED file.
  11. If some storage pool backup volumes cannot be retrieved from the vault, remove the volume entries from the COPYSTGPOOL.VOLUMES.AVAILABLE file.

    If some active-data pool volumes cannot be retrieved from the vault, remove the volume entries from the ACTIVEDATASTGPOOL.VOLUMES.AVAILABLE file.

  12. If all primary volumes were destroyed, no changes are required to the PRIMARY.VOLUMES script and Tivoli Storage Manager macro files.
  13. Review the device configuration file to ensure that the hardware configuration at the recovery site is the same as the original site. Any differences must be updated in the device configuration file. The following example configuration changes require updates to the configuration information:
    • Different device names
    • Use of a manual library instead of an automated library
    • For automated libraries, the requirement of manually placing the database backup volumes in the automated library and updating the configuration information to identify the element within the library. This allows the server to locate the required database backup volumes.
  14. To restore the database to a point where clients can be recovered, ensure that the Tivoli Storage Manager server is halted and then invoke the RECOVERY.SCRIPT.DISASTER.RECOVERY.MODE script file. Enter the script file name at the command line. As an alternative, you can use the recovery script as a guide and manually issue the steps.

    The following steps are an example recovery script:

    1. Copy the Tivoli Storage Manager server options file from the dsmserv.opt file to its original location.
    2. Copy the volume history file that you need for database restore processing from the VOLUME.HISTORY.FILE file to its original location. Use this copy of the volume history file unless you have a more recent copy (after the disaster occurred).
    3. Copy the device configuration file that you need for database restore processing from the DEVICE.CONFIGURATION.FILE file to its original location.
    4. Issue the DSMSERV RESTORE DB command.
    5. Start the server.
    6. Register Tivoli Storage Manager server licenses.
    7. Mark copy storage pool volumes and active-data pool volumes that are retrieved from the vault as available.
    8. Mark copy storage pool volumes and active-data pool volumes that cannot be obtained as unavailable.
    9. Mark primary storage pool volumes as destroyed.

      Due to changes in hardware configuration during recovery, you might have to update the device configuration file in the restored Tivoli Storage Manager database (see Updating the device configuration file

      You can mount copy storage pool volumes and active-data pool volumes upon request, check in the volumes in advance, or manually place the volumes in the library and ensure consistency by issuing the AUDIT LIBRARY command. Use the AUDIT LIBRARY command to ensure that the restored Tivoli Storage Manager database is consistent with the automated library volumes.

  15. If client workstations are not damaged, invoke the RECOVERY.SCRIPT.NORMAL.MODE script file to restore the server primary storage pools. If client workstations are damaged, you might want to delay this action until after all clients are recovered.

    This action is optional because Tivoli Storage Manager can access the copy storage pool volumes and active-data pool volumes directly to restore client data. Using this feature, you can minimize client recovery time because server primary storage pools do not have to be restored first. However, in this scenario, the client workstations were not damaged, so the focus of the administrator is to restore full Tivoli Storage Manager server operation.

    As an alternative, you can use the recovery script as a guide and manually run each step. Run the following steps in this script:

    1. Create replacement primary volumes.
    2. Define the replacement primary volumes to Tivoli Storage Manager.
    3. Restore the primary storage pools from copy storage pools.
      Attention: If the server determines that an inactive file must be replaced but cannot find it in the active-data pool, restoring a primary storage pool from an active-data pool might cause some or all inactive files to be deleted from the database.
  16. Collect the database backup, copy storage pool volumes, and active-data pool volumes that are used in the recovery for return to the vault. For these backup volumes to be returned to the vault by using the routine MOVE DRMEDIA process, issue the following commands:
    update volhist TPBK50 devcl=lib8mm ormstate=mountable
    update volhist TPBK51 devcl=lib8mm ormstate=mountable
    The copy storage pool volumes and active-data pool volumes that are used in the recovery already have the correct ORMSTATE.
  17. Issue the BACKUP DB command to back up the newly restored database.
  18. Issue the following command to check the volumes out of the library:
     move drmedia * wherestate=mountable
  19. Create a list of the volumes to be given to the courier:
    query drmedia * wherestate=notmountable 
  20. Give the volumes to the courier and issue the following command:
    move drmedia * wherestate=notmountable
  21. Issue the PREPARE command.