FAT16 is the file system used by most versions of the MSDOS operating System. Files are managed by means of directories that identify files and their attributes (Read only, Hidden, System, Archive). The root directory entry points to an entry in a File Allocation Table (FAT) that is used to control where information is located on the disk. The disk itself is broken up into nearly 65535 "clusters" that can be accessed by means of a 16 bit address. Files and free space are stored as linked lists of clusters. An older system used for floppy disks and very small hard drives used a 12 bit address with 4096 clusters. The older FAT12 system is hidden within the later FAT16 system. In the FAT16 system, subdirectories are just special files pointed to by other directories and structured like the "Root" directory.

The principle problems with FAT16 are overly large clusters on large disks and a tendency for file space to fragment into a multitude of disconnected pieces over time. The smallest unit of disk allocation is a cluster, and there are only about 65535 clusters per disk. A small file is likely to occupy a lot of space on a large disk. For example on a 1.024GB disk, a cluster is 16384 bytes. That means that a 50 byte file uses up 16384 bytes of storage. The usual cure for cluster size problems is to break the disk into smaller logical drives with smaller clusters.

Fragmentation is a problem because files are read most quickly if a file is written in one contiguous block. As time goes by, it becomes more and more difficult to find large contiguous free areas to write files into. Eventually files may end up written in a number of small pieces requiring a great deal of time consuming head movement for reads and writes. Fragmentation can be corrected by a defragmentation utility that reorders the files on the drive into contiguous blocks.

FAT16 allows only 512 entries in the root directory.

Two copies of the FAT table are maintained in hopes that a damaged FAT can be replaced by the copy. In practice, detecting a damaged FAT is not easy and the backup is almost invariably a copy of the defective table by the time damage is confirmed. File deletion in accomplished by marking the directory entry deleted and writing the special cluster link address 0 to the clusters the file was occupying. Because the directory entry pointer to the file's initial cluster is not cleared, undeletion is possible when neither the directory nor disk space has been reused and the file was not fragmented. In Windows 95 a less haphazard recovery mechanism -- effectively a deleted file directory -- called the "Recycle Bin" was implemented.

FAT file systems have problems with lost cluster strings. These occur when the OS crashes with newly written files in place that are reflected in the FAT, but not in the directories. Lost clusters cause no trouble, but they take up disk space. A rarer problem is a cross link between cluster chains. Unlike lost clusters which are an accommodation to events beyond the control of the file system, cross links are caused by errors in the file system management. Cross-links, lost clusters, and other rarer problems can be fixed by occasional application of a file checker such as CHKDSK or SCANDISK.

last update 051014

Return To Index Copyright 1994-2008 by Donald Kenney.