File Systems
File Systems
Disk Organisation
Before a disk can store data it must be put into a state usable by the computer operating system. This happens when a disk is formatted. The disk is divided up into little boxes or sectors each containing 512 bytes. These sectors in turn are grouped into clusters (sometimes called allocation units).
Cluster 1
Sector 1 Sector 2 Sector 3 (512 bytes) (512 bytes) (512 bytes)
Cluster 2
Sector 1 Sector 2 Sector 3 (512 bytes) (512 bytes) (512 bytes)
All clusters are given the same size and typically run from 2 to 16 sectors. The cluster size depends on the operating system and several variables, including the size of the hard disk or its partitions, and is a key factor in determining operating system efficiency and speed. Each file occupies one or more of these clusters AND a cluster can only contain one file. This means a 100 byte file would occupy part of a cluster with the remaining part of the cluster being wasted. It is therefore better to have clusters as small as possible however there are limitations as are mentioned below. In addition to the area where files are stored, there are other areas set aside on the disk for basic system operations. These are: an area for boot processes (not covered in this article) an area for the file system providing information on the physical location and the properties of the files. When the computer requires a specific file for some purpose, it is this file information that allows the system to find and load that file from disk into RAM for processing. Here FAT and NTFS have completely different approaches.
FAT16
The biggest advantage of FAT16 is that it is compatible across a wide variety of operating systems, including Windows 95/98/Me, OS/2, and Linux. The biggest problem of FAT16 is that it has a maximum of 64K clusters per drive (64K is the largest number that can be contained in 16 binary bits). As hard disks get bigger, the size of each cluster gets larger. In a 2 gigabyte disk, each cluster is 32 kilobytes (2Gb / 64K), meaning that even the smallest file on the drive will take up 32 KB of space. FAT16 also doesn't support compression, encryption, or advanced security techniques.
June 2008 File Systems FAT & NTFS Page 1
Overview Series
FAT32
The FAT32 file system, originally introduced in Windows 95 Service Pack 2, is really just an extension of the original FAT16 file system that provides for a much larger disks and number of clusters per disk. However, FAT32 shares all of the other limitations of FAT16, and adds an important additional limitation - many operating systems that can recognize FAT16 will not work with FAT32 - most notably Windows NT.
FAT Vs NTFS
The FAT systems are wasteful of disk space when used with large drives. Making smaller partitions on a large drive can help reduce this problem. NTFS eliminates the problem of disk space wastage that is encountered with the FAT system however uses much more disk space to store its own information. Not all file systems will work with all versions of Windows although NTFS is becoming the standard for NT, ME, 2000 XP and Vista. NTFS provides advanced features not found in FAT. For example, NTFS includes built-in security features such as file and folder permissions and the Encrypting File System (EFS), which is the technology used to store encrypted files on NTFS volumes. NTFS also provides support for volumes up to 256 terabytes in size. The FAT system has been enjoying a come-back with the introduction of thumb or flash drives. Their smaller capacity makes the FAT system useful.
File Fragmentation
Another problem is file fragmentation. Although a file may require many 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. This means the clusters comprising a file may be scattered all over the disc and the time required to retrieve them inevitably slows the system. To improve the retrieval time, a process known as defragmentation should be periodically performed on the disk. This process relocates file clusters so that they are in close proximity to each other.
Deleting Files
When you delete a file using normal methods you only remove its entry in the file system - you do not affect the actual clusters that comprise the file. There are special programs that can recover these programs providing the operating system has not re-used one or more of the clusters. Special techniques must be used if you wish to delete all traces of a file.
Page 2
June 2008