Gather backup and logical-log tapes before restoring
Before you restore an entire database system, you must gather backup and logical log tapes. If you changed the names of backup and logical log files, you must also manually rename the files to their original file names.
- Backup tapes
- Gather all the tapes from your latest level-0 backup that contain
the storage spaces you are restoring and any subsequent level-1 or
level-2 backups.
Identify the tape that has the latest level-0 backup of the root dbspace on it; you must use this tape first.
- Logical-log tapes
- If at the time of the archive checkpoint, an open transaction started, gather all logical-log tapes before you perform the level-0 backup.
- If you decide not to replay any logical logs, the system can be brought to a consistent state.
- If you decide to replay logical logs, the logs contained within
the archive backup are discarded and you must replay transactions
from the logical log backups.
The starting log file is the oldest log file containing an open transaction at the time of the last restored archive. You can identify that log file from the message that was displayed when the last archive was restored.
Example:
- The ontape -s -L 0 command performs a level-0 backup of the system and displays a message that states that the archive contains logs 2-4.
- The ontape -s -L 1 command performs a level 1 incremental backup of the system and displays a message that states that the archive contains logs 8-9.
The restore of the logical log files uses an archive format, not a log file format. However, the logs contained within the restored archive are in log file format, not an archive format.
File names when restoring from directory
When restoring from a file system directory, ontape requires that storage-space archive and logical-log backup files be named as specified by the TAPEDEV and LTAPEDEV configuration parameters. If files were renamed, including by ontape because of repeated archives and backups, you must manually rename the files to their original file names. To learn about the naming conventions for storage-space archive files and logical-log backup files, see Back up to a directory for the naming conventions of these files.