FAT file system

From Computer History Wiki
Revision as of 16:49, 21 January 2023 by Jnc (talk | contribs) (Gives the basics)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

The File Allocation Table (usually abbreviated to FAT) if the name of a group of related file systems used in MS-DOS and early Windows operating systems. The first was FAT12 (used by floppy disks), from which descended FAT16 and FAT32 (the last used by only by hard disks).

The name comes from the way they indicate which disk blocks of the disk are used by any given file, and which blocks are free and available for use - the 'file allocation table'. (FAT file systems were not the first to use this approach; others OS's, such as ITS, had used a similar approach long before.) The disk contains, at the start of the disk, a large array of entries, one for each 'cluster' (group of blocks) of the disk; each entry indicates whether that cluster is free (and thus available for allocation), or part of a file. For clusters which are part of a file, their entries in the FAT are used to tie them together. (For robustness, there are two identical copies of the FAT.)

The array elements are of size 12, 16 and 32 bits in FAT12, FAT16 and FAT32 file systems. FAT32 was a relatively late addition; it was added in Windows 95 OSR 2.

Unlike the UNIX file system, which strictly separates the functions of the naming of files (via directories), and indicating where the files are stored, FAT file systems to some extent merge these two - again, like earlier file systems. The directory entry of a file indicates which cluster is the first cluster of the file; from there, FAT elements form a linked list of all the clusters in the file.

Like the Unix file system, most directories are stored in what are effectively files; the root directory is a special case, and is stored in a specially allocated area at the start of the disk.

See also

External links