{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

G 1mb log new blocks into empty segment garbage

Info icon This preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: a'ons for commiYed transac'ons –  Garbage collect log Before Transac'on Start Cache Nonvolatile Storage Tom = $200 Tom = $200 Log: Mike = $100 Mike = $100 ANer Updates Are Logged Cache Nonvolatile Storage Tom = $100 Mike = $200 Tom = $200 Mike = $100 Log: Tom = $100 Mike = $200 ANer Commit Logged Cache Nonvolatile Storage Tom = $100 Mike = $200 Tom = $200 Mike = $100 Log: Tom = $100 Mike = $200 COMMIT ANer Copy Back Cache Nonvolatile Storage Tom = $100 Mike = $200 Tom = $100 Mike = $200 Log: Tom = $100 Mike = $200 COMMIT ANer Garbage Collec'on Cache Nonvolatile Storage Tom = $100 Tom = $100 Log: Mike = $200 Mike = $200 Ques'ons •  What happens if machine crashes? –  Before transac'on start –  ANer transac'on start, before opera'ons are logged –  ANer opera'ons are logged, before commit –  ANer commit, before write back –  ANer write back before garbage collec'on •  What happens if machine crashes during recovery? Performance •  Log wriYen sequen'ally –  ONen kept in flash storage •  Asynchronous write back –  Any order as long as all changes are logged before commit, and all write backs occur aNer commit •  Can process mul'ple transac'ons –  Transac'on ID in each log entry –  Transac'on completed iff its commit record is in log Redo Log Implementa'on Volatile Memory Log−head pointer Pending write−backs Log−tail pointer Persistent Storage Log−head pointer Log: ... older Free Garbage Collected Writeback Complete Eligible for GC Mixed: WB Complete Committed Uncommitte...
View Full Document

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern