Read and respond to this message at:
https://sourceforge.net/forum/message.php?msg_id=3230071
By: nobody
Update Sequence
Several structures in NTFS have sequence numbers in them to check for consistancy
errors. They are FILE, INDX, RCRD and RSTR records. Before the record is written
to disk, the last two bytes of each sector are copied to an array in the header.
The update sequence number is then incremented and written to the end of each
sector. If any disk corruption occurs, this technique could detect it.
The Update Sequence Array (usa) is an array of the __u16 values which
belong
to the end of each sector protected by the update sequence record in
which
this array is contained. Note that the first entry is the Update
Sequence
Number (usn), a cyclic counter of how many times the protected record
has
been written to disk. The values 0 and -1 (ie. 0xffff) are not used.
All
last __u16's of each sector have to be equal to the usn (during reading)
or
are set to it (during writing). If they are not, an incomplete multi
sector
transfer has occured when the data was written.
The maximum size for the update sequence array is fixed to:
maximum size = usa_ofs + (usa_count * 2) = 510 bytes
The 510 bytes comes from the fact that the last __u16 in the array has
to
(obviously) finish before the last __u16 of the first 512-byte sector.
This formula can be used as a consistency check in that usa_ofs +
(usa_count * 2) has to be less than or equal to 510.
______________________________________________________________________
You are receiving this email because you elected to monitor this forum.
To stop monitoring this forum, login to SourceForge.net and visit:
https://sourceforge.net/forum/unmonitor.php?forum_id=44084
|