The RECOVER Utility

 <  Day Day Up  >  

The RECOVER Utility

The recovery of DB2 data is an automated process rigorously controlled by the database management system. Figure 32.1 shows the flow of normal DB2 recovery. The standard unit of recovery for DB2 is the table space. As of DB2 V6, indexes can be copied using the COPY utility and recovered using the RECOVER utility. The DB2 COPY utility is used to create an image copy backup. All DB2 image copy data set information is recorded in the DB2 Catalog in the SYSIBM.SYSCOPY table. It is not necessary to keep track of the image copy data sets externally because DB2 manages this information independent of the application code.

Figure 32.1. DB2 recovery.

graphics/32fig01.gif


DB2 is also responsible for keeping a log of all changes made to table spaces. With a few exceptions, all updates are recorded in the DB2 active log . When an active log is full, DB2 creates an archive log . Many archive logs are created during normal DB2 application processing. All this information is stored in the DB2 Directory's SYSIBM.SYSLGRNX table and the Boot Strap Data Set (BSDS). Refer to Chapter 22, "The Table-Based Infrastructure of DB2," for a complete description of the internal DB2 tables and data sets.

The DB2 RECOVER utility reads all control information pertaining to data recovery and applies the recorded changes contained in the copies and logs, as instructed by the DBMS and the RECOVER utility control parameters.

Basically, the RECOVER utility is used to restore DB2 table spaces and indexes to a specific point in time. You can run two forms of the RECOVER utility: RECOVER TABLESPACE and RECOVER INDEX . Both are discussed in the following sections.

 <  Day Day Up  >  


DB2 Developers Guide
DB2 Developers Guide (5th Edition)
ISBN: 0672326132
EAN: 2147483647
Year: 2004
Pages: 388

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net