OpenTP1 Version 7 Operation

[Contents][Index][Back][Next]

7.4.18 File recovery at archive-journal source node

If an error occurs with the DAM, TAM or ISAM file at an archive-journal source node, the file can be recovered by a backup file and journal. Use the jnlls command and OS command to compare the size of the backup file with that of the journal needed for updating the defective file. If the size of the backup file is larger, recover the defective file at an archive-journal source node. If the size of the backup file is smaller, recover the defective file at an archive-journal target node. By doing so, a shorter time is required for transfer of the file, making it possible to recover the file more quickly. The procedure for recovering the file at each node is described below.

Organization of this subsection
(1) Backup file larger than journal requirement for recovery
(2) Backup file smaller than journal requirement for recovery

(1) Backup file larger than journal requirement for recovery

The backup file must be retained at an archive-journal source node before starting recovery. If the backup file was created in the offline mode, the run ID of the online journal service at the next archive-journal source node is required for recovery of the defective file. If the backup file was created in the online mode, the run ID of the online journal service at the archive-journal source node used at that time is required for recovery of the defective file. In the description that follows, this run ID is referred to as R.

To recover the defective file, take the following steps:

  1. Execute the jnlunlfg command to unload the archive journal file needed for recovery. This archive journal file contains journals with run IDs of R or later. Check the run IDs by using the jnlarls and jnlls commands.
  2. Execute the jnlunlfg command to unload all system journal files containing the journals that were not archived at the archive-journal source node.
  3. Execute the jnlsort command to integrate the journals from the global archive unload journal file referred to in step 1., using the node identifier and the run ID of R at the archive-journal source node as the key.
  4. Use the OS command to transfer the integrated journals to the archive-journal source node.
  5. Specify the transferred journal file and the unload journal file referred to in step 2. and then execute the jnlsort command to integrate more journals.
  6. Restore the backup file in a DAM file or a TAM file. For DAM file, use the damrstr command to restore; for TAM file, use the tamrstr command.
  7. Using the integrating journal file referred to in step 5., recover the file at the archive-journal source node. Use the damfrc command to recover a DAM file and the tamfrc command to recover a TAM file. For recovery of an ISAM file, see the manual Indexed Sequential Access Method ISAM.

(2) Backup file smaller than journal requirement for recovery

The backup file must be retained at an archive-journal target node before starting recovery. If the backup file was created in the offline mode, the run ID of the online journal service at the next archive-journal source node is required for recovery of the defective file. If the backup file was created in the online mode, the run ID of the online journal service at the archive-journal source node used at that time is required for recovery of the defective file. In the description that follows, this run ID is referred to as R.

To recover the defective file, take the following steps:

  1. Execute the jnlunlfg command to unload the archive journal file needed for recovery. This archive journal file contains journals with run IDs of R or later. Check the run IDs by using the jnlarls and jnlls commands.
  2. Execute the jnlunlfg command to unload all system journal files containing the journals that were not archived at the archive-journal source node.
  3. Use an OS command to transfer the unload journal file referred to in step 2. to the archive-journal target node.
  4. Specify the transferred unload journal file referred to in step 3. and the global archive unload journal file referred to in step 1. and then execute the jnlsort command to integrate journals, using the node identifier and run ID of R of the archive-journal source node as the key.
  5. The archive journal node requires a physical file for the DAM file or TAM file on the OpenTP1 file system, to restore the backup file. If that physical file has not been created, use the damload command for DAM file or use the tamcre command for TAM file to create it. To restore the backup file in a DAM file or a TAM file, use the damrstr command for DAM file or use the tamrstr command for TAM file.
  6. Using the integrating journal file referred to in step 4., recover the file at the archive-journal target node. Use the damfrc command to recover a DAM file and the tamfrc command to recover a TAM file. For recovery of an ISAM file, see the manual Indexed Sequential File Management ISAM.
  7. Back up the restored DAM file or TAM file again.
  8. Transfer the backed up file to the archive-journal source node using a command of the OS.
  9. Restore the transferred backup file in the original DAM file or TAM file, using the damrstr command for DAM file or using the tamrstr command for TAM file.