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

SQL Anywhere 10.0.1 » SQL Anywhere Server - Database Administration » Backup and Data Recovery » Backup and recovery internals

Transactions and the rollback log Next Page

The automatic recovery process

When a database is shut down during normal operation, the database server performs a checkpoint so that all the information in the database is held in the database file. This is a clean shutdown.

Each time you start a database, the database server checks whether the last shutdown was clean or the result of a system failure. If the database was not shut down cleanly, it automatically takes the following steps to recover from a system failure:

  1. Recover to the most recent checkpoint    All pages are restored to their state at the most recent checkpoint by copying the checkpoint log pages over the changes made since the checkpoint.

    Page A, the checkpoint log copy of the page, is copied to the database file to overwrite the dirty page. The transaction log contains changes made to page A since the checkpoint.
  2. Apply changes made since the checkpoint    Changes made between the checkpoint and the system failure, which are held in the transaction log, are applied.

  3. Rollback uncommitted transactions    Any uncommitted transactions are rolled back, using the rollback logs.