1RECOVERY AND ATOMICITY
To ensure atomicity despite failures, we first output information describing the modifications to stable storage without modifying the database itself.
2
Log
is a sequence of log records, which maintains information about update activities on the database. Each entry in the log is referred to as a log record.
3
Transaction Identifier
identifies different transactions in the log and helps in tracking their progress and status during recovery
4
Data Item Identifier
identifies the location of the data-item within the database and facilitates the identification of affected data during recovery.
5
Old Value
stores the original value of a data item before it was modified by a transaction.
6
New Value
contains the new value that was assigned to a data item by a transaction.
7
LOG-BASED RECOVERY
is a technique to ensure database consistency after a system failure. It involves maintaining a transaction log, which records all operations performed by transactions before they are committed to the database and be used as a recovery mechanism.
8
Analysis Phase
Analyzes the transaction log to determine the last checkpoint and identify transactions that were active but not yet committed at the time of failure.
9
Redo Phase
Reapplies committed transactions from the log to ensure that all changes are reflected in the database.
10
Undo Phase
Rolls back incomplete transactions that were active but not committed at the time of failure to maintain atomicity.
11
FAILURE WITH LOSS OF NONVOLATILE STORAGE
recovery failure that occurs due to hardware malfunctions, disasters like fires or floods, or human errors like accidental deletion or corruption
12
New Primary
When the backup site takes over processing
13
Concurrent transactions
all transactions share a single disk buffer and a single log
14
Buffer block
can have data items updated by one or more transactions
15
Recovery algorithms
are essential components of DBMS that ensure the database can be restored to a consistent state after a failure or crash.
16
Recovery algorithms
are essential components of DBMS that ensure the database can be restored to a consistent state after a failure or crash.
17
Logging
is the process of recording important events and changes in a database system to a transaction log file.
18
Transaction Rollback
is the process of undoing the effects of incomplete or aborted transactions to restore the database to a consistent state.
19
Redo phase
replay updates of all transactions, whether they committed, aborted, or are incomplete
20
Undo phase
undo all incomplete transactions