Javatpoint Logo
Javatpoint Logo

Why Recovery is Needed in DBMS?

In basic terms, the computer's operating system oversees the assurance that whenever a transaction is dispatched to a database management system (DBMS) for execution, all required operations are executed accurately. It ensures that the consequences of these actions are appropriately recorded in the database and do not disrupt other transactions.

Certain actions performed by the transaction t cannot be committed to the database whereas other actions of the transaction t are not possible according to the database management system. This essentially occurs when an activity fails to complete all of its activities, even when it has completed part of those.

Why Recovery is Needed in DBMS

Categories of failures

The inability of the computer's database to complete an operation or any other form of damage to the system is essentially considered a failure. The rejection of the transaction may fundamentally be caused by any of these categories of failures:

  • Operation Failure: This kind of failure happens whenever an operation is no longer accepted or cannot be completed.
  • Computer Fail/Crash: This form of failure often happens when a transaction is being executed and may be caused by either software, hardware, or network errors. In essence, hardware malfunctions are classified as hardware breakdowns.
  • System Failure: This kind of failure is caused by a process that is carried out within the process, such as division by 0 or integers. This kind of problem is sometimes referred to as a transaction failure, and it may also result from conceptual programming errors or incorrect value selection. Furthermore, an individual may stop the process from proceeding while it is being executed, which might result in process rejection.
  • Transaction Abortion: This situation arises when a transaction cannot be successfully completed due to specific conditions, leading to its cancellation. For instance, if a transaction attempts to transfer funds from a bank account with insufficient balance, it would be aborted to maintain data integrity. Such occurrences, commonly termed as 'transaction abortion,' are integral to preserving the consistency of the database. Including provisions for handling such exceptions within transactions is crucial to prevent data inconsistencies and ensure transactional reliability.
  • Concurrency Control Enforcement: When multiple processes are in a state of inactivity or when there is a fundamental violation of serialization, the process with the concurrency control technique has the authority to determine whether to terminate the process and restart it.
  • Disc Failure: This kind of failure essentially happens when a disc fails due to a read/write head collision or some other problem that causes the disc to lose information. This could occur while the process is being read or written.
  • Catastrophe: Another name for this is physical issues. It generally refers to an unending variety of issues, such as malfunctioning air conditioning or electricity, accidentally replacing discs or recordings, and user installation of incorrect tape.
  • Network Failure: A network failure happens whenever the client and database server's connection to one another is disrupted. Numerous factors, including device malfunctions, software errors, and natural disasters, may cause this.
  • Deadlock: A deadlock occurs when numerous transactions are awaiting the releasing of locks on the resources they require to go forward from one another. This can result in a transaction being stuck, in which case the system would have to terminate any of the transactions in order to break the deadlock.
  • Software flaws: When an operation is being executed, bugs in the DBMS software might result in unexpected behavior or problems. If improperly handled appropriately, this might result in losing information or damage.
  • Power Interruption: If the system's recovery process fails to effectively manage the ongoing transactions, an electrical failure may result in the system shutting down abruptly and causing loss of information or damage.
  • Data Corruption: A number of factors, including network issues, software defects, and hardware malfunctions, may lead to corruption of information. Inconsistent data and compromised database integrity may result from corruption that is not identified and fixed.

Since restoration guarantees that information can be recovered to a reliable and precise form in the event of breakdowns or mistakes, it is a crucial component of Database Management Systems (DBMS).

Youtube For Videos Join Our Youtube Channel: Join Now


Help Others, Please Share

facebook twitter pinterest

Learn Latest Tutorials


Trending Technologies

B.Tech / MCA