...
If the file has been allocated more than one cluster, then the FAT table entry will contain the address of the second cluster (which is also the index number of the second cluster’s entry in the FAT table). The second cluster entry points to the third, and so forth. A FAT entry like this forms a linked list commonly called a cluster chain.
Figure 12-3- File Allocation Table and Directory Entry relationship illustrates the relationship between the directory entry and the FAT.
Panel | ||||
---|---|---|---|---|
|
...
| |
In the figure above, the directory entry for a file points to the 40th entry in the FAT table. The 40th entry points to the 41st, the 41st to the 46th; the 46th is not a pointer, as the entry contains a special end-of-cluster-chain marker. The This means that for Figure 12-3, the 41st cluster is the final cluster allocated to the file.
Other entries in the FAT area in illustrated Figure 12-3 illustrated in the figure above are either not allocated to a file, or allocated to a file whose cluster chain is terminated by the 43rd entry.
...
Other values that can be stored in a cluster’s entry in the FAT are special markers for:
- End-of-cluster-chain: this cluster is the final cluster for a file.
- Cluster-not-allocated (free cluster mark): no file is using this cluster.
- Damaged-cluster: this cluster cannot be used.
NOTE: Updating the FAT table is time consuming, but updating it frequently is very important. If the FAT table gets out of sync with its files, files and directories can become corrupted, resulting in the loss of data (see section 12-6 “Optional Journaling System” Optional Journaling System).