What is Database Backup?
What is Database recovery techniques
Why recovery is needed? (What causes a Transaction to fail?)
The 3 Important Recovery Techniques from transaction failures:
The figure below illustrates the use of Shadow paging techniques:
Recovery Techniques and Need of RecoveryPooja Dixit
Recovery Techniques and Need of Recovery, 3 states of database Recovery:, DBMS Failure , Transaction Failure…, System Crash…, Disk Failure…,LOG BASED , CONCURRENT TRANSACTION, Checkpoint…
This presentation discusses the following topics:
What is Recovery ?
Database Recovery techniques
System log
Working of Commit and Roll back
Recovery techniques
Backup techniques
Recovery Techniques and Need of RecoveryPooja Dixit
Recovery Techniques and Need of Recovery, 3 states of database Recovery:, DBMS Failure , Transaction Failure…, System Crash…, Disk Failure…,LOG BASED , CONCURRENT TRANSACTION, Checkpoint…
This presentation discusses the following topics:
What is Recovery ?
Database Recovery techniques
System log
Working of Commit and Roll back
Recovery techniques
Backup techniques
Introduction to transaction processing concepts and theoryZainab Almugbel
Modified version of Chapter 21 of the book Fundamentals_of_Database_Systems,_6th_Edition with review questions
as part of database management system course
Transaction Processing; Concurrency control; ACID properties; Schedule and Discoverability; Serialization; Concurrency control and Recovery; Two Phase locking; Deadlock Shadow Paging
Adbms 34 transaction processing and recoveryVaibhav Khanna
A transaction is an atomic unit of work that is either completed in its entirety or not done at all.
– For recovery purposes, the system needs to keep track of when the transaction starts, terminates, and commits or aborts.
Transaction states:
– Active state
– Partially committed state
– Committed state
– Failed state
– Terminated State
Similar to What is Database Backup? The 3 Important Recovery Techniques from transaction failures (20)
Instructions for Submissions thorugh G- Classroom.pptxJheel Barad
This presentation provides a briefing on how to upload submissions and documents in Google Classroom. It was prepared as part of an orientation for new Sainik School in-service teacher trainees. As a training officer, my goal is to ensure that you are comfortable and proficient with this essential tool for managing assignments and fostering student engagement.
We all have good and bad thoughts from time to time and situation to situation. We are bombarded daily with spiraling thoughts(both negative and positive) creating all-consuming feel , making us difficult to manage with associated suffering. Good thoughts are like our Mob Signal (Positive thought) amidst noise(negative thought) in the atmosphere. Negative thoughts like noise outweigh positive thoughts. These thoughts often create unwanted confusion, trouble, stress and frustration in our mind as well as chaos in our physical world. Negative thoughts are also known as “distorted thinking”.
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
Read| The latest issue of The Challenger is here! We are thrilled to announce that our school paper has qualified for the NATIONAL SCHOOLS PRESS CONFERENCE (NSPC) 2024. Thank you for your unwavering support and trust. Dive into the stories that made us stand out!
The French Revolution, which began in 1789, was a period of radical social and political upheaval in France. It marked the decline of absolute monarchies, the rise of secular and democratic republics, and the eventual rise of Napoleon Bonaparte. This revolutionary period is crucial in understanding the transition from feudalism to modernity in Europe.
For more information, visit-www.vavaclasses.com
Ethnobotany and Ethnopharmacology:
Ethnobotany in herbal drug evaluation,
Impact of Ethnobotany in traditional medicine,
New development in herbals,
Bio-prospecting tools for drug discovery,
Role of Ethnopharmacology in drug evaluation,
Reverse Pharmacology.
The Roman Empire A Historical Colossus.pdfkaushalkr1407
The Roman Empire, a vast and enduring power, stands as one of history's most remarkable civilizations, leaving an indelible imprint on the world. It emerged from the Roman Republic, transitioning into an imperial powerhouse under the leadership of Augustus Caesar in 27 BCE. This transformation marked the beginning of an era defined by unprecedented territorial expansion, architectural marvels, and profound cultural influence.
The empire's roots lie in the city of Rome, founded, according to legend, by Romulus in 753 BCE. Over centuries, Rome evolved from a small settlement to a formidable republic, characterized by a complex political system with elected officials and checks on power. However, internal strife, class conflicts, and military ambitions paved the way for the end of the Republic. Julius Caesar’s dictatorship and subsequent assassination in 44 BCE created a power vacuum, leading to a civil war. Octavian, later Augustus, emerged victorious, heralding the Roman Empire’s birth.
Under Augustus, the empire experienced the Pax Romana, a 200-year period of relative peace and stability. Augustus reformed the military, established efficient administrative systems, and initiated grand construction projects. The empire's borders expanded, encompassing territories from Britain to Egypt and from Spain to the Euphrates. Roman legions, renowned for their discipline and engineering prowess, secured and maintained these vast territories, building roads, fortifications, and cities that facilitated control and integration.
The Roman Empire’s society was hierarchical, with a rigid class system. At the top were the patricians, wealthy elites who held significant political power. Below them were the plebeians, free citizens with limited political influence, and the vast numbers of slaves who formed the backbone of the economy. The family unit was central, governed by the paterfamilias, the male head who held absolute authority.
Culturally, the Romans were eclectic, absorbing and adapting elements from the civilizations they encountered, particularly the Greeks. Roman art, literature, and philosophy reflected this synthesis, creating a rich cultural tapestry. Latin, the Roman language, became the lingua franca of the Western world, influencing numerous modern languages.
Roman architecture and engineering achievements were monumental. They perfected the arch, vault, and dome, constructing enduring structures like the Colosseum, Pantheon, and aqueducts. These engineering marvels not only showcased Roman ingenuity but also served practical purposes, from public entertainment to water supply.
Unit 8 - Information and Communication Technology (Paper I).pdfThiyagu K
This slides describes the basic concepts of ICT, basics of Email, Emerging Technology and Digital Initiatives in Education. This presentations aligns with the UGC Paper I syllabus.
The Art Pastor's Guide to Sabbath | Steve ThomasonSteve Thomason
What is the purpose of the Sabbath Law in the Torah. It is interesting to compare how the context of the law shifts from Exodus to Deuteronomy. Who gets to rest, and why?
The Indian economy is classified into different sectors to simplify the analysis and understanding of economic activities. For Class 10, it's essential to grasp the sectors of the Indian economy, understand their characteristics, and recognize their importance. This guide will provide detailed notes on the Sectors of the Indian Economy Class 10, using specific long-tail keywords to enhance comprehension.
For more information, visit-www.vavaclasses.com
This is a presentation by Dada Robert in a Your Skill Boost masterclass organised by the Excellence Foundation for South Sudan (EFSS) on Saturday, the 25th and Sunday, the 26th of May 2024.
He discussed the concept of quality improvement, emphasizing its applicability to various aspects of life, including personal, project, and program improvements. He defined quality as doing the right thing at the right time in the right way to achieve the best possible results and discussed the concept of the "gap" between what we know and what we do, and how this gap represents the areas we need to improve. He explained the scientific approach to quality improvement, which involves systematic performance analysis, testing and learning, and implementing change ideas. He also highlighted the importance of client focus and a team approach to quality improvement.
What is Database Backup? The 3 Important Recovery Techniques from transaction failures
1. What is Database Backup?
• Copying and archiving of computer data so it may be used to restore the original after a
data loss event.
• Purpose is to recover data after it is lost from corruption or deletion.
• Second purpose is to recover data from an earlier time.
What is Database recovery techniques
Recovery techniques are used to ensure database consistency and transaction automaticity and
durability despite failures.
Why recovery is needed? (What causes a Transaction to fail?)
There are several reasons that could cause a transaction to fail in the middle of execution
1. A computer failure (system crash): A hardware or software error occurs in the
computer system during transaction execution. If the hardware crashes, the contents of
the computer’s internal memory may be lost.
2. A transaction or system error : Some operation in the transaction may cause it to fail,
such as integer overflow or division by zero. Transaction failure may also occur because
of a logical programming error. In addition, the user may interrupt the transaction during
its execution.
3. Local errors or exception conditions detected by the transaction.
4. Disk failure: Some disk blocks may lose their data because of a disk read/write head
crash. This may happen during a read or a write operation of the transaction.
5. Physical problems and catastrophes: This refers to an endless list of problems that
includes power or air-conditioning failure, fire, theft, sabotage, overwriting disks or tapes
by mistake, and mounting of a wrong tape by the operator.
There are many different approaches to recover a database:
Manual reprocessing & a variety of automated recovery techniques.
1. Manual Reprocessing
The database is periodically backed up (a database save) and all transactions applied since the
last save are recorded. If the system crashes, the latest database save is restored and all of the
transactions are re-applied (by users) to bring the database back up to the point just before the
crash.
Limitations:
• Time required to reapply transactions
• Transactions might have other (physical) potential failures
• Reapplying concurrent transactions is not straight forward.
2. Automated Recovery
There are several types of automated recovery techniques including: Deferred update,
Immediate update, Shadow paging, etc.
1
2. A transaction can be in one of the following states:
• Active - when the transaction just begins
• Partially Committed - after the last operation has completed (but before the commit
point is reached)
• Failed - Normal operation is prevented (e.g., in the event of a system crash)
• Aborted - Transaction is rolled back. That is, all of its effects are undone
• Committed - Transaction completes all operations and moved the database to the next
consistent state
The System Log
To be able to recover from failures that affect transactions, the system maintains a log to keep
track of all transactions that affect the values of database items. Each transaction writes the
following information to the log:
• Start(T) - the fact that transaction T has started
• Write(T, X, old_value, new_value) - the fact that transaction T has written to item X
with the new_value. old_value is also maintained.
• Read(T,X)-the fact that transaction T has read data item X either:
Commit(T)-transaction T committed or Abort(T) - transaction T was aborted
Recovery techniques use the following operations:
UNDO (Backward Recovery): Similar to rollback except that it applies to a single operation
rather than to a whole transaction.
REDO (Forward Recovery): This specifies that certain transaction operations must be redone
to ensure that all the operations of a committed transaction have been applied successfully to the
database.
The 3 Important Recovery Techniques from transaction failures:
1. Deferred Update Recovery: Also called NO-UNDO, REDO Technique
This technique defers or postpones any actual updates to the database until the transaction
reaches it commit point.
• During transaction execution, the updates are written to the log file.
• After the transaction reaches it commit point, the log file is force-written to disk, then
the updates are recorded in the database.
• If the transaction fails before reaching its commit point, there is no need to UNDO
any operations because the transaction has not affected the database on disk in any
way.
• REDO may be necessary.
A typical deferred update protocol uses the following rules:
2
3. 1. A transaction cannot change the database on disk until it reaches its commit point.
2. A transaction does not reach its commit point until all its update operations are
recorded in the log file and the log file is force-written to disk.
3. Because the database is never updated on disk until after the transactions commits,
there is never the need to UNDO any operations. That’s why a recovery techniques based
on deferred update are therefore known as NO UNDO, REDO techniques.
Example:
T1: Ra Rd Wd C
T2: Rb Wb Rd Wd C
T3: Ra Wa Rc Wc C
T4: Rb Wb Ra Wa C
Log file:
Start(T1)
Write(T1, d, old, new)
Commit(T1)
Start(T4)
Write(T4, b, old, new)
Write(T4, a, old, new)
Commit(T4)
Start(T2)
Write(T2, b, old, new)
Start(T3)
Write(T3, a, old, new)
s y s t e m c r a s h
Since T1 and T4 committed, their changes were written to disk. However, T2 and T3 did not
commit, hence their changes were not written to disk. To recover, we simply ignore those
transactions that did not commit.
Advantages:
• Recovery is made easier.
• Any transaction that reached the commit point (from the log) has its writes applied to the
database.
• All other transactions are ignored.
• Cascading rollback does not occur because no other transaction sees the work of another
until it is committed.
Disadvantages:
Concurrency is limited: Must employ Strict 2PL which limits concurrency.
2. Immediate Update Recovery: also called (UNDO, NO-REDO)
• The database is physically updated before the transaction reaches to its commit point.
• UNDO may be necessary when a transaction fails.
3
4. • REDO is not needed.
A typical deferred update protocol uses the following rules:
1. In immediate update techniques, although the database can be updated immediately,
update operations must be recorded in the log (on disk) before being applied to the
database.
2. There is never a need to REDO any operations of committed transactions (this is
called the UNDO/NO-REDO recovery algorithm).
3. The effect of all active transactions at the time of failure must be undone.
Advantages:
Immediate update allows higher concurrency because transactions write continuously to the
database rather than waiting until the commit point.
Disadvantages:
Step 2 above can lead to cascading rollbacks - time consuming and may be problematic.
3. Shadow paging
• Is a technique for providing automaticity and durability properties related to transaction
control.
• This technique does not require the use of a log in a single-user environment. In a
multiuser environment, a log may be needed for the concurrency control method.
• Shadow paging considers the database to be made up of a number of fixed size disk pages
(or disk blocks)—say, n—for recovery purposes. A directory(page table) with n entries
is constructed, where the ith
entry points to the ith
database page on disk.
• The idea is to maintain 2 directories (page tables) during the lifetime of a transaction,
Current directory & the Shadow directory.
• The directory is kept in main memory if it is not too large, and all references—reads or
writes—to database pages on disk go through it.
• Initially both the directories are identical. Only current directory is used for data item
accesses during execution of the transaction.
• Whenever any page is about to be written for the first time-a copy of this page is made on
to an unused page.
• When a transaction begins executing, the current directory—whose entries point to the
most recent or current database pages on disk—is copied into a shadow directory. The
4
5. shadow directory is then saved on disk while the current directory is used by the
transaction.
The figure below illustrates the use of Shadow paging techniques:
Advantages:
• The overhead of maintaining the transaction log file is eliminated.
• Since there is no need for undo or redo operations, recovery is significantly fast.
Disadvantages:
• Copying the entire page table is very expensive.
• Complex storage management strategies.
5
6. shadow directory is then saved on disk while the current directory is used by the
transaction.
The figure below illustrates the use of Shadow paging techniques:
Advantages:
• The overhead of maintaining the transaction log file is eliminated.
• Since there is no need for undo or redo operations, recovery is significantly fast.
Disadvantages:
• Copying the entire page table is very expensive.
• Complex storage management strategies.
5