Main -> Documentation -> OCLC SiteSearch Record Builder -> Record Builder Administration -> Database Recovery

Recovering a Corrupted Record Builder Database

 

If a Record Builder database (a local database that you populate and/or modify with the Record Builder application included with OCLC Database Builder) becomes corrupted, you can use a database backup and the journal files created since the backup to recover the database. This document provides a procedure for database recovery.


Document Conventions

  • <WebZ_root> is the location of the SiteSearch environment that contains the Record Builder application.
  • database_dir is a database's top-level directory.
  • Database_name is the database's name.
  • Items or commands you must type appear in quotes, like this: "j". Type them without the quotes.

Procedure

Follow these steps to recover a corrupted database.

1. Check the database's .dsc file to see whether it contains any sparse indexes.
2. Use the SiteSearch Database Operations Tool (SSDOT) to restore the most recent backup of the database.

3. Copy the journal files to <WebZ_root>/dbbuilder/dbs/database_dir/bers/. The journal files reside in <WebZ_root>/dbbuilder/dbs/database_dir/journal/ by default.

Note:   Journal files reside in <WebZ_root>/dbbuilder/dbs/database_dir/journal/ by default unless you specify a different location for them in the [ExtendedServicesDbUpdate] section of the database's configuration file.

4. Rename each journal file in <WebZ_root>/dbbuilder/dbs/database_dir/bers/ as follows:

  • Start with the oldest file (you can find the oldest file from the date and time stamps in the file names).
  • Rename this file as database_name.ber.v1.
  • Rename the second-oldest file as database_name.ber.v2, the next oldest as database_name.ber.v3, and so on.

For example:

You would rename this file:        To this:
record_D20000105_T105806.ber   database_name.ber.v1
record_D20000105_T110430.ber   database_name.ber.v2
record_D20000105_T111301.ber   database_name.ber.v3
record_D20000105_T111547.ber   database_name.ber.v4
record_D20000105_T111640.ber   database_name.ber.v5
record_D20000105_T111722.ber   database_name.ber.v6
5. Start SSDOT.
6. Type "5" and press Enter to select the Advanced Options menu from the SSDOT Main Menu.
7. Apply the transaction contained in the first journal file to the database:
  • Type "3" and press Enter.
  • When prompted, type the database name and press Enter.
  • You see a list of BER volumes available for the database, like this:
     Volume: 1 saved 100/01/05 11:26:48 
    
     Volume: 2 saved 100/01/05 11:26:48 
    
     Volume: 3 saved 100/01/05 11:26:48 
    
     Volume: 4 saved 100/01/05 11:26:48 
    
     Volume: 5 saved 100/01/05 11:26:48 
    
     Volume: 6 saved 100/01/05 11:26:49 
  • Type "1" and press Enter to select the first BER volume.
  • Press Enter to return to the Advanced Options menu.
  • Type "j" and press Enter to verify that this job completed successfully.

8. Sort the index terms (option 6 on the menu) for the record contained in the journal file:

  • Type "6" and press Enter.
  • When prompted, type the database name and press Enter.
  • Press Enter to return to the Advanced Options menu.
  • Type "j" and press Enter to verify that this job completed successfully.

9. Add the index terms (option 7 on the menu) for the record contained in the journal file:

  • Type "7" and press Enter.
  • When prompted, type the database name and press Enter.
  • Press Enter to return to the Advanced Options menu.
  • Type "j" and press Enter to verify that this job completed successfully.

10. Does the database have any sparse indexes (you checked for this in step 1)?

  • Yes. Go to step 11.
  • No. Go to step 13.

11. Sort the sparse index terms (option 8 on the menu) for the record contained in the journal file:

  • Type "8" and press Enter.
  • When prompted, type the database name and press Enter.
  • Press Enter to return to the Advanced Options menu.
  • Type "j" and press Enter to verify that this job completed successfully.

12. Add the the sparse index terms (option 9 on the menu) to the database for the record contained in the journal file:

  • Type "9" and press Enter.
  • When prompted, type the database name and press Enter.
  • Press Enter to return to the Advanced Options menu.
  • Type "j" and press Enter to verify that this job completed successfully.
13. Repeat steps 7-12 for each of the other journal files you need to apply to the database. In step 7, select volume 2 the second time you repeat these steps, volume 3 the third time, and so on until you have applied each of the journal files to the database.
14. Press Enter to return the the SSDOT Main Menu.
15. View the database log files or print the database log files to ensure that you have successfully applied the journal files to the database.
16. Exit SSDOT.

17. Verify that the database has been repaired:

18. Delete the files in <WebZ_root>/dbbuilder/dbs/database_dir/bers/.
19. Back up the database.
20. Delete the journal files in the database's journal directory (usually <WebZ_root>/dbbuilder/dbs/database_dir/journal/).


See Also

Record Builder Journal Files
Performing Online Updates to Local Databases with Record Builder
Record Builder Process Model and System Overview
Backing Up a Database



[Main][Documentation][Support][Technical Reference][Community][Glossary][Search]

Last Modified: