Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SQL Anywhere 12.0.0 (Français) » SQL Anywhere Server - SQL Usage » Remote data and bulk operations » Importing and exporting data » Rebuilding databases


Minimize downtime when rebuilding a database

It is recommended that you make backup copies of your database files before rebuilding a database. Also, verify that no other scheduled backups can rename the production database log. If the log is renamed, the transactions from the renamed logs must be applied to the rebuilt database in the correct order.

 ♦  To minimize the downtime during a rebuild
  1. Using dbbackup -r, create a backup of the database and log, and rename the log.

    For more information, see Backup utility (dbbackup).

  2. Rebuild the backed up database on another computer.

  3. Perform another dbbackup -r on the production server to rename the transaction log.

  4. Run dbtran on the transaction log and apply the transactions to the rebuilt server.

    For more information, see Log Translation utility (dbtran).

  5. Shut down the production server and copy the database and log.

  6. Copy the rebuilt database onto the production server.

  7. Run dbtran on the log from Step 5.

  8. Start the server on the rebuilt database, but do not allow users to connect.

  9. Apply the transactions from Step 8.

  10. Allow users to connect.