Start of Content Area

Procedure documentation Performing Emergency Logical-Log Backup Using SAP Scripts (ON-Archive)  Locate the document in its SAP Library structure

Use

This section describes how to use the SAP script arcpanic with ON-Archive to automatically perform an emergency logical-log backup on your Informix database.

Prerequisites

You have performed Preparing for Emergency Logical-Log Backup using SAP Scripts (ON-Archive).

Procedure

  1. Enter the following from the command line when signed on as user informix :
  2. ./arcpanic

    The script starts as follows:

    This script handles the situation after the Logical Logs have filled up:

     

    Press <RETURN> to continue...

     

    Mount Tape from Volume-Set ONDATARTRLOG in /dev/rmt/0hc

    Press <RETURN> to continue...

  3. Mount the correct tape volume.
  4. The system prompts you with the details of the volume mounted:

    ON-Archive: Media Identification Function

    Tape Information:

     

    Vset : ONDATARTRLOG

    Volume : 000000

     

    ARC-W-01845, Initializing this media may overwrite an ON-Archive volume.

     

    Proceed and overwrite contents, Cancel operation, or Retry
    with another volume?

  5. When you have mounted the correct volume, confirm the prompt.
  6. The script writes the logical-log files to the volume set ONDATARTRLOG :

    Enter (P/C/R): p

    Save set 21850 being written to vset ONDATARTRLOG.

    Logfile LF00000897 being processed.

    Logfile LF00000898 being processed.

    Logfile LF00000899 being processed.

    Logfile LF00000900 being processed.

    Logfile LF00000901 being processed.

    Logfile LF00000902 being processed.

    Logfile LF00000903 being processed.

    Logfile LF00000904 being processed.

    Logfile LF00000905 being processed.

    Logfile LF00000906 being processed.

    Logfile LF00000907 being processed.

    Logfile LF00000908 being processed.

    Logfile LF00000909 being processed.

    Logfile LF00000910 being processed.

    Logfile LF00000911 being processed.

    Logfile LF00000912 being processed.

    Logfile LF00000913 being processed.

    Backup started

     

    14:24:49 arcpanic: ONCATLGR is already running

  7. Catalog the above tape volume in ON-Archive as described below. Leave the same tape volume in the tape drive and confirm the prompts as they appear.
  8. This is necessary because the previous step was done without ON-Archive , which does not function when the logical log is full.

    Now the tape volume for the backups must be cataloged:

     

    Devices available for ONARCHIVE

     

    DEVICE # DEVICE NAME

    ----------------------------------

    1 /dev/rmt/0hc

    Enter the device number (1) or (C)ancel : 1

    Please mount volume ONDAT1 of ONDATARTRLOG and press < RETURN > ** READ **

     

    Request id 00021850 rebuilt as 00000003.

    Note

    To fit in with your normal logical-log backups, you have to copy the volume set ONDATARTRLOG to the volume set where you normally keep backed up log files, LOGTAP . This is described below.

    You have to copy the Saveset, generated by the Emergency Backup Request, to a Volume on Tape.

    Choose as the source Volume Set: ONDATARTRLOG and as the destination Volume Set you normally backup to (LOGTAP) !

    To perform the copy, you have to enter the following ON-Archive commands manually (that is, outside the script). The first command registers the copy command in ON-Archive and the second command executes the copy command:

    The OnArchive-Commands should look like:

    onarchive 'copy/vset=ONDATARTRLOG/destination=LOGTAP/request=<Request-ID>'

    <Request-ID> is the ID you find after the 'rebuilt as' statement

    onarchive 'execute/request=<Request-ID of the Copy Request>'

    In this example, the <Request-ID> is 00000003. The next prompt tells you that this copy is not possible if you only have one tape drive:

    If you've got access to only one tape-drive, write the <Request-ID> of the

    'rebuilt as' request on the tape and keep this volume safe. You will need it

    if you have to do a logical recovery !!!

  9. Perform the copy following the instructions given.
  10. SAP recommends that you do a full archive of the database to ensure that you do not encounter problems using the logical-log files that have just been backed up in this emergency situation:

    SAP recommends you to perform a Level-0 archive after the situation

    'logical logs full' has cleared up, to make sure that you do not

    run into problems if you have to perform logical recovery in

    the future.

     

    Press < RETURN > to continue...

  11. Perform a full (level-0) archive. Refer to Creation of an Archive (ON-Archive).

Result

The full logical-log is now backed up, allowing the database to continue processing.

You must now check to see that the emergency logical-log backup has completed successfully. Refer to Checking Emergency Backup Result with Activity Log (ON-Archive).

 

See also:

Informix documentation