19.4.2 Example 2: Recover to the most recent synchronization point
(1) Use the pdclose command to close RDAREAs in error shutdown status
pdclose -r rdarea01,rdarea02 |
(2) Use the pdlogls command to check for the current system log file
In the case of a HiRDB/Parallel Server, check the system log files at the back-end servers at which rdarea01 and rdarea02 are located.
(3) Use the pdlogswap command to swap system log files
In order to unload the contents of the current file, the system log files are swapped. In the case of a HiRDB/Parallel Server, swap the system log files at the back-end servers at which rdarea01 and rdarea02 are located.
(4) Use the pdlogunld command to unload what was the current system log file
Unload the contents of the current file identified in step (2). In the case of a HiRDB/Parallel Server, unload the contents of the current system log files at the back-end servers at which rdarea01 and rdarea02 are located.
pdlogunld -d sys -g log01 -o /unld/unldlog02 |
(5) Use the pdrstr command to recover RDAREAs to the most recent synchronization
pdrstr -m /rdarea/mast/mast01 -g backupg1 -K /pdcopy/admfile
-l /unld/unldlog01 -w /tmp/sortwork -r rdarea01,rdarea02 |
- Explanation
- -m: Specifies the name of the first HiRDB file in the master directory RDAREA.
- -g: Specifies the name of a differential backup group.
- -K: Specifies the name of a HiRDB file system area for storing the differential backup management file.
- -l: Specifies the name of the unload log file.
- -w: Specifies the name of the work directory for sorting.
- -r: Specifies the names of the RDAREAs (rdarea01 and rdarea02) that are to be recovered.
(6) Use the pdcopy command to back up recovered RDAREAs
pdcopy -m /rdarea/mast/mast01 -M r -r rdarea01,rdarea02,...
-g backupg1(S) -b /pdcopy/backup01 -d a -K /pdcopy/admfile -L 5
-o /pdcopy/rfile |
- Explanation
- -m: Specifies the name of the first HiRDB file in the master directory RDAREA.
- -M: Specifies the referencing-permitted mode as the backup acquisition mode.
- -r: Specifies the RDAREAs that are to be backed up.
- The RDAREA group specified here becomes the differential backup group. The RDAREAs to be backed up cannot be changed in the middle.
- -g: Specifies the name of the differential backup group.
- For a full backup, specify (S) with the differential backup group name. The differential backup group name specified here must be specified when a differential backup is made subsequently.
- -b: Specifies a name for the backup file (full backup file name).
- -d: Specifies a backup type:
- a: Full backup
- b: Accumulation-differential backup since the last full backup
- c: Accumulation-differential backup since either the last accumulation-differential backup or the last full backup
- d: Differential backup
- For details on an accumulation-differential backup, see 6.5.4 Creating an accumulation-differential backup.
- -K: Specifies the name of the HiRDB file system area for storing the differential backup management file.
- -L: Specifies the size (in megabytes) of the differential backup management file.
- -o: Specifies the name of the history file for differential backups.
(7) Use the pdrels command to open recovered RDAREAs by releasing their error shutdown status
pdrels -r rdarea01,rdarea02 -o |
It is recommended that after the command has executed you check whether or not the execution results are correct. For details on how to check command execution results, see the manual HiRDB Version 8 Command Reference.