You get a bonus - 1 coin for daily activity. Now you have 1 coin

Database recovery (using database backup, using transaction log, recovery via rollback, roll forward)

Lecture



Database recovery is used for damages that prevent the user from opening the database or working with it.

If there is damage to the database created in the Access Database, to restore it, you must:

§ to close the database. When working on a network, you need to make sure that other users have closed the database;

§ create a backup copy of the database;

§ to execute the command Service / Service data / Restore;

§ indicate the name of the folder and the file of the database being restored.

The next method of database maintenance is backup. The main purpose of database backup is to prevent loss of information and is implemented by one-time or periodic copying and archiving of the most valuable information. Backup consists in creating a backup copy of the database and placing it on auxiliary storage media: hard disks, diskettes, optical disk drives, magnetic tapes.

When organizing a backup, the administrator solves such questions as:

§ which devices to choose for backup;

§ when and with what frequency to perform backups.

It is important to periodically check the correctness of the backup performed by trial restoration.

Replication - creation of special copies (replicas) of the database, with which users can work simultaneously on different workstations.

Transaction log Recover through rollback

The implementation in DBMS of the principle of preserving intermediate states, confirming or rolling back a transaction is provided by a special mechanism, to support which a certain system structure is created, called the Transaction Log. The transaction log contains additional information about database changes and is designed to ensure reliable data storage in the database.

The purpose of logging database changes is to ensure that the consistent state of the database can be restored after any kind of failure (hardware and software). The basis for maintaining the integrity of the database is the transaction mechanism.

When a database is restored after a soft failure, the log contains physical consistency points of the database — the points in time in which the external memory contains consistent results of operations that ended before the corresponding point in time, and there are no results of operations that did not end.

The basis of database recovery after a hard failure is a log and a backup copy of the database. Recovery begins with a reverse copy of the database from an archive copy. Then, for all completed transactions in the log in the forward direction, all operations are performed, for transactions that have not ended by the time of the failure, rollback is performed.


Comments


To leave a comment
If you have any suggestion, idea, thanks or comment, feel free to write. We really value feedback and are glad to hear your opinion.
To reply

Databases, knowledge and data warehousing. Big data, DBMS and SQL and noSQL

Terms: Databases, knowledge and data warehousing. Big data, DBMS and SQL and noSQL