ASA Database Administration Guide
Backup and Data Recovery
Understanding backups
The transaction log is a separate file from the database file. It stores all changes to the database. Inserts, updates, deletes, commits, rollbacks, and database schema changes are all logged. The transaction log is also called the forward log or the redo log.
The transaction log is a key component of backup and recovery, and is also essential for data replication using SQL Remote or the Replication Agent.
By default, all databases use transaction logs. Using a transaction log is optional, but you should always use a transaction log unless you have a specific reason not to. Running a database with a transaction log provides much greater protection against failure, better performance, and the ability to replicate data.
For more information on how to use a transaction log to protect against media failure, see Protecting against media failure on the database file.
Like the database file, the transaction log is organized into pages: fixed size areas of memory. When a change is recorded in the transaction log, it is made to a page in memory. The change is forced to disk when the earlier of the following happens:
The page is full.
A COMMIT is executed.
In this way, completed transactions are guaranteed to be stored on disk, while performance is improved by avoiding a write to the disk on every operation.
Configuration options are available to allow advanced users to tune the precise behavior of the transaction log. For more information, see COOPERATIVE_COMMITS option [database], and DELAYED_COMMITS option [database].
A transaction log mirror is an identical copy of the transaction log, maintained at the same time as the transaction log. If a database has a mirrored transaction log, every database change is written to both the transaction log and the transaction log mirror. By default, databases do not have transaction log mirrors.
A transaction log mirror provides extra protection for critical data. It enables complete data recovery in the case of media failure on the transaction log. A mirrored transaction log also enables a database server to carry out automatic validation of the transaction log on database startup.
For more information, see Protecting against media failure on the transaction log.