Use the onbar -r -e command to perform a warm or cold external restore. This command marks the storage spaces as physically restored and restores the logical logs. The following diagram shows the external restore syntax.
Performing an External Restore with ON-Bar: |-- -r-- -e--+----------------------+--+----------------+-------> +- -p------------------+ | (2) | +- -t--time------------+ '- -q--name------' | (1) | '-------- -n--last_log-' >--+-----+--+------------------+--------------------------------| '- -O-' +- -f--filename----+ | .--------------. | | V | | '---dbspace_list-+-'
Element | Purpose | Key Considerations |
---|---|---|
-r | Specifies a restore | In a cold restore, if you do not specify storage space names, all of them are marked as restored. |
-e | Specifies an external restore | Must be used with the -r option. In a warm external restore, marks the down storage spaces as restored unless the -O option is specified. |
dbspace_list | Names one or more storage spaces to be marked as restored in a warm restore | If you do not enter dbspace_list or -f filename and the database server is online or quiescent, ON–Bar marks only the down storage spaces as restored. If you enter more than one storage-space name, use a space to separate the names. |
-f filename | Restores the storage spaces that are listed in the text file whose pathname filename provides | To avoid entering a long list of storage spaces every time, use this option. The filename can be any valid UNIX or Windows filename. |
-n last_log | Indicates the number of the last log to restore (IDS) | If any logical logs exist after this one, ON–Bar does not restore them and data is lost. The -n option does not work with the -p option. |
-O | Restores online storage spaces | None. |
-p | Specifies an external physical restore only | After the physical restore completes, you must perform a logical restore because XPS does not support whole-system restore. |
-q name | Allows you to assign a session name to the external restore (XPS) | DBSERVERNAMErandom_number is the default session name. The session name must be unique and can be up to 128 characters. |
-t time | Restores the last backup before the specified point in time. If you pick a backup made after the point in time, the restore will fail. | You can use a point-in-time restore in a cold
restore only. You must restore all storage spaces.
How you enter the time depends on your current GLS locale convention. If the GLS locale is not set, use English-style date format. See Restoring Data to a Point in Time. |