Patent ID: 7519628

Claim:
A method for replaying a log file of a storage system, comprising: performing a pre-processing phase that determines that one or more transactions of the log file need to be replayed; performing a redo phase wherein the one or more transactions that are determined to need to be replayed are redone, wherein the one or more transactions that need to be redone are transactions committed to the log file but occur after a last page of the log file that is committed to a storage device; performing an undo phase wherein one or more transactions are undone, wherein the one or more transactions that are undone include transactions that were not yet committed to the log file; and flushing data dirtied during the undo phase from a cache of the storage system to a disk of the storage system, wherein the flushing of data dirtied during the undo phase represents a partial flush of the cache, thereby obviating a need to flush all data dirtied during replay of the log file.