RezwanAhmed & His Team || Software Engineer

Posts tagged “FAT

FAT : File Allocation Table – Old System Of Windows

FAT File System

FAT gets its name from the use of a kind of database called a File Allocation Table that contains an entry for each cluster on the disk. The FAT system has been in use by Microsoft since before DOS 1 (the first version was devised by a teenager named Bill Gates) and has undergone several revisions. There are versions called FAT12, FAT16, and FAT32. The numbers refer to the number of bits used for the cluster entries in the table. More recent PC users may find it hard to believe but in 1987 the FAT system then in use (in DOS 3) was unable to read a hard drive (or more accurately, volume) bigger than 32 MB. (That’s right, 32 megabytes). By the time of DOS 6, the upper limit had been enlarged in several steps to 2 GB but the ever increasing size of hard disks made yet another revision necessary. With Windows 95B, FAT32 was introduced, increasing the upper limit to 2 terabytes (theoretically but not practically). These continual problems with disk size arose from several causes, including the fact that the number of entries in FAT is limited by the finite number of bits used for describing the location of a cluster. For example, FAT16 can hold no more than 2^16 or 65, 526 cluster entries (actually somewhat less). Another factor is that the number of sectors per cluster is also limited.

A further problem with bigger disks is the large amount of wasted space or “slack”. Since there are a fixed number of clusters available, larger disks mean that the cluster size has to be increased in order to fill the available space. However, this results in more and more unutilized disk space since a typical file is rarely close to an even multiple of a cluster size. For example, a FAT32 system uses 16 KB clusters for partition sizes between 16 and 32 GB. A 20 KB file would require two 16 KB clusters actually occupying 32 KB of space. A mere 1 KB file still requires 16 KB of space. A typical large disk might have 30% or even 40% of its space wasted this way. Making smaller partitions alleviates slack but with 200 GB disks now common, and ever-bigger ones on the way, partitioning is no longer a practical solution.

Another problem is file fragmentation. Although a file may require several clusters, the clusters need not be in close physical proximity on the disk. When a file is loaded to the disk the operating system chooses unused clusters wherever it finds them. If many files consist of widely separated parts, the time required to retrieve them for program use inevitably slows the system (hence the need for defragging).

It has to be remembered that the FAT system was first devised when the computer environment was very different from what it is today. Indeed, the PC as we know it did not even exist. FAT was intended for systems with very little RAM and small disks. It required much less in the way of system resources than did the file systems in Unix and other big computer systems and did its job well when systems were small. NTFS and Windows XP are practical for consumer PCs today only because the available resources of RAM and hard drive size have reached levels far exceeding anything imagined when FAT was first put into use.

Actually, the FAT system has been enjoying something of a come-back. Thumb or flash drives have become very common and these are of a size that makes the FAT system useful. The smaller sizes are even formatted in FAT16.