Question

log-based recovery Recovery: Assuming a redo-only recovery, what should the database do to recover if the...

log-based recovery

Recovery: Assuming a redo-only recovery, what should the database do to recover if the following is the contents of the log upon recovery:

• T1 write X: was 3, now 6

• T2 write Y: was 2, now 0

• T1 commit

• T3 write X: was 6, now 4

• T2 commit

0 0
Add a comment Improve this question Transcribed image text
Answer #1

T1 write X: was 3, now 6
T2 write Y: was 2, now 0
T1 commit
T3 write X: was 6, now 4
T2 commit

Transaction Ti needs to be redone if log contains record Ti start and either the record Ti commit or the record Ti abort.
In above Log we can see that Transaction T1 and T2 commit before System crash.
Therefore, Transaction T1 and T2 will be Redone.

Add a comment
Know the answer?
Add Answer to:
log-based recovery Recovery: Assuming a redo-only recovery, what should the database do to recover if the...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • For the system given in figure 3 identify if schedule 2 is conflict equivalent and view...

    For the system given in figure 3 identify if schedule 2 is conflict equivalent and view equivalent to schedule 1. Give proper reasons for you answer. Resolve the issues in schedule 2 by adopting appropriate locking scheme and apply deadlock prevention scheme to ensure prevention of deadlocks and starvation. (7) Table 2:Serial Schedule 1 T1   T2   T3   T4   T5                Read(X)                Read(Z)                Read(Y)                Write(Z)   ...

  • Question 1: Assume that initially A-5 and B:10. The following are 3 transactions on A and...

    Question 1: Assume that initially A-5 and B:10. The following are 3 transactions on A and B (→ denotes assignmen): TI : A+B → A: A+B → B T2: A+B → B: A+B → A * For each transaction, a) add necessary read- and write-actions to the computation; b) show the undo/redo-log records for each of the transactions. Question 2: The following is a sequence of undo/redo-log records generated by two transactions, T and U: COMMIT U>:<T,E,50.51: <COMMIT T> Suppose...

  • 1. What is the difference between Two-Phase Locking (2PL) and Strict Two-Phase Locking? What condition to Strict 2PL prevent that 2PL does not prevent? 2. What are deadlocks? What are two techniques...

    1. What is the difference between Two-Phase Locking (2PL) and Strict Two-Phase Locking? What condition to Strict 2PL prevent that 2PL does not prevent? 2. What are deadlocks? What are two techniques for detecting and resolving deadlocks? 3. In the figure below, R(X, y) means read database item X into variable y and W(X, y) means write variable y into database item y. Column T1 shows transaction T1's operations and column T2 shows T2's operations. Columns Aand_B show the values...

  • Instruction: Do any 10 of the 14 questions. Each question is worth 10 points. (For each...

    Instruction: Do any 10 of the 14 questions. Each question is worth 10 points. (For each True/False question, if it is true, answer T and give reasons for your answer. If it is false, answer F and give a explicit counterexample or other explanation of why it is false.) 1) True or False: The set {x : x = : x = tany, y e [0,5)} is an compact subset of R, the set of all real numbers with the...

  • 1. (10 points) Write an efficient iterative (i.e., loop-based) function Fibonnaci(n) that returns the nth Fibonnaci...

    1. (10 points) Write an efficient iterative (i.e., loop-based) function Fibonnaci(n) that returns the nth Fibonnaci number. By definition Fibonnaci(0) is 1, Fibonnaci(1) is 1, Fibonnaci(2) is 2, Fibonnaci(3) is 3, Fibonnaci(4) is 5, and so on. Your function may only use a constant amount of memory (i.e. no auxiliary array). Argue that the running time of the function is Θ(n), i.e. the function is linear in n. 2. (10 points) Order the following functions by growth rate: N, \N,...

  • Knowledge Use the properties of logarithms to expand the following expression. VE log Each logarithm should...

    Knowledge Use the properties of logarithms to expand the following expression. VE log Each logarithm should involve only one variable and should not have any radicals or exponents. You may assume that all variables are positive. YZ DO log 0 X 6 ? Sub Type here to search # % 3

  • For each graph below, you are instructed to find the RMS. However, do NOT find it....

    For each graph below, you are instructed to find the RMS. However, do NOT find it. Instead, find the equation for each "segment" of the graph. For example: Do only the green part. Remember to not skip any steps and explain/show HOW you got the equations. Period (T= 6 ms) Vminimum = 0V,Vpeak = 6V тії Voltage waveform falls across R2=102. Vrms=?, Power dissipation in R2? Write equations for each segment V1 R2 {R2} v7(t) = 2t v2(t) = -2t...

  • The Taylor polynomial approximation pn (r) for f(x) = sin(x) around x,-0 is given as follows: TL ...

    The Taylor polynomial approximation pn (r) for f(x) = sin(x) around x,-0 is given as follows: TL 2k 1)! Write a MATLAB function taylor sin.m to approximate the sine function. The function should have the following header: function [p] = taylor-sin(x, n) where x is the input vector, scalar n indicates the order of the Taylor polynomials, and output vector p has the values of the polynomial. Remember to give the function a description and call format. in your script,...

  • Write a C++ program called ts.cpp that implements the topological sorting algorithm based on the DFS...

    Write a C++ program called ts.cpp that implements the topological sorting algorithm based on the DFS algorithm. Your program should read an input file name and determine if the input graph is a DAG (= directed acyclic graph) or not. If the graph is not a DAG, your program has to stop without further processing. However, if it’s a DAG, your program should display the starting node(s), popping-off order, and topologically sorted list. In the problem, you can assume that...

  • Consider the transactional database shown in the following table. Transaction ID Items Bought T100 Plum, Apple,...

    Consider the transactional database shown in the following table. Transaction ID Items Bought T100 Plum, Apple, Peach, Orange, Pear, Banana T200 Cherry, Apple, Peach, Orange, Pear, Banana T300 Plum, Mango, Orange, Pear, Kiwi, Strawberry T400 Plum, Watermelon, Avocado, Orange, Banana T500 Avocado, Apple, Orange, Lemon, Pear CONDITION: The minimum support is 60% and minimum confidence is 70%. Based on the CONDITION above, answer the following five questions. (1) Find all frequent itemsets using the Apriori algorithm. Show how the algorithm...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT