Document Type | Technical Information
Category | Backup/Recovery
Document Number | TBATI026
Overview
This guide explains the recovery modes that can be performed in Tibero.
Methods
Crash Recovery
Recovery performed when the first node boots up after all nodes (instances) have gone down.
It is divided into two stages: Cache Recovery and Transaction Recovery, and is automatically performed during boot.
- Cache recovery (Rolling Forward) Restores the DB buffer cache to the state just before shutdown. It reads the redo logs to replay transactions performed after the last checkpoint.
- 1st Pass: Reads redo logs and identifies blocks to be recovered
- 2nd Pass: Performs recovery on the identified data blocks
- Transaction Recovery (Rolling Backward) Uses undo to rollback all uncommitted transactions at the time of shutdown.
Instance Recovery
When some nodes (instances) have shut down in TAC, one of the remaining nodes becomes the recovering instance and reads the redo logs of the shut down instances to perform recovery.
- Except for excluding redo from currently active nodes, recovery proceeds in the order of cache recovery and transaction recovery, similar to Crash Recovery in many aspects.
- In TAC, this recovery is automatically performed when a node shuts down.
Media Recovery
If current data files cannot be used due to disk errors, file deletion, or other reasons, this recovery restores from a backup file at a specific point in time and then recovers using archive logs and redo logs afterwards.
- Unlike other recoveries, this is not performed automatically.
- Users execute it via SQL commands such as alter database recover automatic;
NoteIf Tibero is shut down normally (normal, post_tx, immediate, switchover), a checkpoint is performed, so recovery does not occur on the next boot.If Tibero is shut down abnormally (abort, abnormal), recovery (cache, transaction recovery) occurs on the next boot and may take considerable time depending on the amount of recovery needed.
Cache recovery takes a significant amount of time during I/O operations and is proportional to the size of the redo logs to be read and the number of data blocks to be recovered.
Transaction recovery starts after cache recovery is completed, and the database is opened. The database does not wait for transaction recovery to complete before opening. Sessions performing transaction recovery after opening are treated the same as other sessions.