Show TOC

Call Options of BRRESTORE

Call options of BRRESTORE
-------------------------

You can restore an entire database backup or parts of it starting from an off-line or online BRBACKUP backup with BRRESTORE, including the non-database files and directories that were saved. The subdirectories in sapdata directories are automatically created if they do not exist. The redo log files archived with BRARCHIVE can also be restored (possibly at the same time as the database restore).

BRRESTORE supports the following call options:

[-a|-archive|-a1|-archive1 <log_no>[=<rest_dir>]|<log_no1>-<log_no2> [=<rest_dir>]|<log_no_list>] <log_no>,<log_no1>-<log_no2> - log sequence numbers of the redo log files that are to be restored from the first copies of the off-line redo log files. <rest_dir> - restore directory into which the redo log files are to be restored, otherwise the original directory is used.

[-a2|-archive2 <log_no>[=<rest_dir>]|<log_no1>-<log_no2> [=<rest_dir>]|<log_no_list>] <log_no>,<log_no1>-<log_no2> - log sequence numbers of the redo log files that are to be restored from the second copies of the off-line redo log files. <rest_dir> - restore directory into which the redo log files are to be restored, otherwise the original directory is used.

[-b|-backup <log_name>|last] <log_name> - name of the BRBACKUP log file that is used for the database restore, "last" - last successful backup Default: last.

[-c|-confirm] unattended mode - in contrast to BRBACKUP/BRARCHIVE only mount tape confirmations are suppressed, all other BRRESTORE confirmation requests must be answered.

[-d|-device tape|tape_auto|disk|pipe|pipe_auto|util_file] Device type for the restore. Default: tape.

[-h|-help [version]] Help information about BRRESTORE options (version of BRRESTORE).

[-k|-compress [no|yes|hardware]] Compression type - if software compression was switched on during the backup, you should use "yes". BRRESTORE does not differentiate internally between "no" and "hardware". Default: no.

[-l|-language D|E] language in which BRRESTORE messages are output, "D" - German, "E" - English. Default: E.

[-m|-mode all|full|<tablespace_name>[=<rest_dir>]|<file_ID> [=<rest_dir>]|<file_ID1>-<file_ID2>[=<rest_dir>] |<generic_path>|<object_list> List of the objects (tablespaces, database files, non-database files or directories) which are restored. "all" restores all the tablespaces, without control files or online redo log files. "full" restores the entire backup, including non-database files, directories, control files or online redo log files. <file_ID> refers to the ORACLE file ID for data files. File ID 0 identifies the control file. IDs with leading zeros identify the online redo log files. If <generic_path> is a full path name, then a database file, a non-database file or a directory is restored, otherwise <generic_path> must contain at least the ORACLE home directory. In this case, all the database DATA files whose name starts with this path are selected. <rest_dir> - restore directory into which the files are restored, otherwise the original directory is used. <object_list> is a list of the tablespace/file specifications separated by commas. Default: all.

[-n|-number <file_pos>|init_ora|init_sap|reorg_log|det_log|sum_log] With this option you can directly restore a file from the tape (without specifying the log name of the backup or the log sequence number). Enter the position of the file on tape. <file_pos> - position of the file on tape. init_ora - init<SID>.ora is restored, corresponds to position 2. init_sap - init<SID>.sap is restored, corresponds to position 3. reorg_log - reorg<SID>.log is restored, corresponds to the third-to-last position on tape det_log - the detailed BRBACKUP/BRARCHIVE log is restored, corresponds to the next to last position on tape. sum_log - the summary BRBACKUP/BRARCHIVE log is restored, corresponds to the last position on the tape.
[-o|-output dist|time[,time|dist]] Extended output in the detailed log. Default: normal output. -o|-output dist - generates information on the distribution of the files on the volumes used (tape, hard disk). -o|-output time - generates additional information on the time it takes to restore individual files.

[-p|-profile <profile>] BRRESTORE profile name. Default: init<SID>.sap.

[-q|-query [check]] Query option - the restore process is not started. Only tape names and other resources that are required for the restore are output. "check" also checks whether the correct tapes were inserted into the tape units.

[-r|-parfile <parfile>] Parameter file for an external backup program. Default: no parfile.

Notes: - The options -d, -k, -m and -r can be preselected using the corresponding BRRESTORE profile parameters. - Only one of the options -a, -b or -n may be set. If none are set, -b last is assumed. - BRRESTORE with the option -a can be started in parallel to BRRESTORE with the option -b or -n. - To restore a complete off-line backup (reset database), you must use the option -m full. - The key word "all" can be combined with other specifications in an <object_list> (for example, non-database files or directories). - All the <file_ID>s used and all the file IDs occurring in the area <file_ID1>-<file_ID2> must be recognized by the database. - Non-database files and directories must be defined with their full path. - Database data files can be defined with a full or generic path. The generic path must contain the ORACLE home directory and an additional generic specification, for example, a sapdata directory. - online redo log files can only be explicitly accessed with the redo log group number which must also be provided with a leading zero. - the ORACLE control file can only be explicitly accessed with file ID 0.

Examples:

brrestore -b last -m all Restore all the tablespaces without the ORACLE control file and the online redo log files starting from the last successful backup.

brrestore -b bcnmhluz.aft -m full Restore all the files starting from backup bcnmhluz.aft, including the ORACLE control files and online redo log files.

brrestore -m all,/usr/sap/C11/SYS/exe/run,/usr/sap/C11/SYS/profile Restore all the tablespaces, SAP executables and profiles.

brrestore -m /oracle/C11/sapdata1=/oracle/C11/sapdata5 Restore all the database data files from the subdirectories of /oracle/C11/sapdata1 into the directory /oracle/C11/sapdata5.

brrestore -b last -m 1-10,01-04,0 Restore all the database data files with ORACLE file IDs between 1 and 10 inclusive, the four online redo log files and the control file.

brrestore -m 0 Restore the ORACLE control file.

brrestore -b last -m /oracle/C11/sapdata2/ddicd_5/ddicd.data5 Restore a database data file.

brrestore -a 200-220 Restore the archived redo log files into the archiving directory for the log sequence numbers from 200 to 220 inclusive

brrestore -a 40-70=/oracle/C11/sapbackup,71-90=/oracle/C11/sapreorg Restore the archived redo log files with the log sequence numbers from 40 to 70 inclusive into the directory /oracle/C11/sapbackup, and the log sequence numbers from 71 to 90 inclusive into the directory /oracle/C11/sapreorg

New init<SID>.sap parameter
---------------------------

Three new init<SID>.sap parameters were introduced to support the restore of the database using SAPDBA:

cpio_in_flags - cpio options for importing the files from tape, default: -iduvB, example: cpio_in_flags = -iduvB

uncompress_cmd - decompression command, no default, example: uncompress_cmd = "uncompress -c $ > $"

tape_pos_cmd - command for positioning on tape, no default, example: tape_pos_cmd = "mt -t $ fsf $"

Installation information

Adjusting the profile init<SID>.sap

System administration changes

Restore of the saved files.