NTFS Documentation: Log File Technique

Interest

When you want to write a file on a storage unit, you have to update the file itself plus some tables of the filesystem (say as an example the date of the file). At this point, you need a transaction made of 2 operations (update the file itself, update the date of the file).

If the transaction is realized, you are sure that your file is written on the storage unit, and that the filesystem has been left in a defined state.

If the transaction is not realized (in case of e.g. power failure, or system failure in general), the filesystem is in an undefined state. The only way for you to put it back in a defined (and sane) state (this operation is called a roll-back) is to log in a special file, the log file, which operations of the transaction have been successfully completed.

What Windows NT® does

At the first access to the disk after a system failure, the system read the log file and rolls back all the operations to the beginning of the last transaction.

What is important with this technique


Regis Duchesne at VIA, ECP, France
Last modified: Sun Jan 24 23:40:06 PST 1999