代写代考 COMP9315 Final Exam

COMP9315 Final Exam

COMP9315 Final Exam

Copyright By PowCoder代写 加微信 powcoder

The University of Wales

COMP9315 DBMS Implementation
Final Exam

DBMS Implementation

[Instructions] [Notes] [PostgreSQL] [C]

[Q1] [Q2] [Q3] [Q4] [Q5] [Q6] [Q7] [Q8]

Question 8 (6 marks)

Consider the followng three transactions:

T1: T2: T3:
read(X) read(Y) read(X)
X = X + 1 Y = Y * 2 read(Y)
write(X) read(X) X = X – Y
read(Y) X = X + Y Y = Y – 3
Y = Y + 1 write(Y) write(X)
write(Y) write(X) write(Y)
commit commit commit

Consider also the following concurrent schedule on these three transactions:

T1: R(X) W(X) R(Y) W(Y) C |
T2: R(Y) R(X) W(Y) W(X) | system
T3: R(X) R(Y) | failure

Note that we have omitted the computation on X
and Y from the schedule.
You should assume that it occurs somwhere between the
read and the write of the relevant variable.
The line of | symbols indicates where
a system failure occurred.

Making the following assumptions:

R = read, W = write, C = commit, A = abort

initial value of X was 5, initial value of Y was 2
the system uses write-ahead undo/redo logging

log entries are written to disk just before the relevant write operation starts
the log is empty before T1 starts; scans of the log can go all the way to its start

the transaction descriptions show all of the intended operations

any operations not completed before system failure do not actually happen

answer these questions:

Show all entries written to the log as the transactions progress in the given schedule

(include ,
, and
, entries
as well as entries for updates)

Show how recovery takes place when the system restarts after the system failure

which transactions are placed on the undo and redo lists
which undo operations occur; which redo operations occur

Show all working.

Instructions:

Type your answer to this question into the file called q8.txt

Submit via:   give cs9315 exam_q8 q8.txt

or via: Webcms3 > exams > Final Exam > Submit Q8 > Make Submission

End of Question

程序代写 CS代考 加微信: powcoder QQ: 1823890830 Email: powcoder@163.com