A server manages the objects a1, a2,... an. The server provides two operations for its clients:
Read (i) returns the value of
Write(i, Value) assigns Value to
The transactions T, U and V are defined as follows:
T: x= Read (i); Write(j, 44);
U: Write(i, 55);Write(j, 66);
V: Write(k, 77);Write(k, 88);
Describe the information written to the log file on behalf of these three transactions if strict two-phase locking is in use and U acquires ai and aj before T. Describe how the recovery manager would use this information to recover the effects of T, U and V when the server is replaced after a crash. What is the significance of the order
of the commit entries in the log file?
As transaction U acquires aj first, it commits first and the entries of transaction T follow those of U. For simplicity we show the entries of transaction V after those of transaction T.
On recovery, the recovery manager sets default values in the data items a1...an. It then starts at the end of the log file (at position P10). It sees V has committed, finds P9 and V's intentions list
The order of the commit entries in the log file reflect the order in which transactions committed. More recent transactions come after earlier ones. Recovery starts from the end, taking the effects of the most recent transactions first.
You might also like to view...
A smaller file size reduces the ____ from an FTP server or website.
A. download time B. animation effects C. upload time D. cost of downloading
What happens to previously applied artistic effects when you apply a new artistic effect?
What will be an ideal response?
When you click and drag a file from the contents of the trash to a new location on your computer, the file is ____.
A. duplicated B. restored C. saved D. deleted
A variable is said to be alive if ____________________ for the variable is available.
Fill in the blank(s) with the appropriate word(s).