Thread: Chkdsk?
View Single Post
hczim's Avatar
Posts: 13 | Thanked: 0 times | Joined on Jan 2006
#13
Just for the sake of completeness ...
Originally Posted by fredly
For example, if you wanted to find out where file "stuff.txt" was stored,
you would look up "stuff.txt" in the FAT table and the latter would tell you that the file was stored at locations x, y, z, ... on the disk.
The place to look up "stuff.txt" is the directory, not the FAT. And the directory also is what tells you where to find its first block (which happened to be the same as a floppy sector those days when FAT was introduced). All the FAT does is that it tells you where you find your next block. Basically, it is just a table (indexed by your current block) which returns the address of the next block (if any). Unallocated blocks get a magic number instead, so you can also tell from the FAT where to put your new data.

fsck.vfat and CHKDISK check for inconsistencies in this structure. One of them would be that there are next-sector links in the FAT but no file pointing at them (which would lead to the mentioned capacity loss), another one which isn't less likely would be that there are blocks being pointed to by more than one file (which would result in data corruption).

Of course, all this kind of damage can only happen if something fatal happened before - it's never a result of normal operation. This was much more likely when floppies were common than it is now and I can't tell when it happened to me last time.

So I'd guess that if you get data corruption it will most likely be more than just some free blocks vanishing - you'll notice it. Running fsck.vfat (or chkdisk) without any sign of damage won't hurt, but for me it's not worth the (small) hassle. Having a safe backup is - by far - more important.