Windows file system

How files are stored on the hard drive in windows operating system.

What is disk partition?


Disk partition is the logical division of the hard drive. During this period a Master boot record or Guide partition table is created base two standards, the Basic input out standard (BIOS) for master boot record and Unified Extensible firmware interface (UEFI) for Guide partition table (GPT).

The master boot record is located on the first sector of a disk. The specific address on the disk is Cylinder: 0, Head: 0, Sector: 1. This part of the hard drive  holds the operating system which is loaded into the computer main memory during boot process.
For the partition to hold data, it has to be formatted. During formatting a file system is created either with file allocation table (FAT) for early versions of windows or New Technology File system (NTFS) for windows version from Window NT to windows 10.

What is File Allocation Table (FAT)

FAT was created as a windows file standard by Microsoft in 1977. FAT has different version like FAT 32, EX FAT and FAT 16. FAT is still in use till today on portable storage devices. FAT uses sectors to store data.

What is a sector?

A sector is a minimum storage unit of a hard drive. It’s a subdivision of a track on a optical disc. Each sector stores a fixed amount of user-accessible data, traditionally 512 bytes for hard disk drives (HDDs) and 2048 bytes for CD-ROMs and DVD-ROMs. The small size of a sector makes stored files scattered all over the hard drive (HDD) therefore, causing the read/write head of the hard drive to spine round the hard drive just to retrieve a single file.

What this means is that if a file size is greater than a sector, the single file will be spread across different sectors. These chunks of files are called fragmented file. Scattered files on the hard drive are can cause hard drive to crash easily. To solve this problem Microsoft introduced a new file system in 1993 known as New Technology File System (NTFS).
What is New Technology File System (NTFS)

NTFS was introduced by Microsoft in 1993 to solve the minimum size problem of sectors in FAT. NTFS began with windows NT 3.1 and since then NTFS has been the new file system for windows operating system. In NTFS eight sectors are combined into one to form a cluster. This makes cluster the minimum storage unit for NTFS. A cluster which composed of eight sectors has a minimum size of size of 4Kb, mathematically gotten multiply 512bytes by 8 which gives 4096bytes approximated to 4kb.

Great Microsoft was able to solve the problem of minimum storage unit for hard drives running windows operating system but the problem of fragmented files became an inherent one. Apart from fragmented file problem which NTFS Inherited from FAT. NTFS has a problem of waste. This waste comes as a result of trying to increase the minimum storage units for hard drives.

Where is the waste coming from?
The minimum size for NTFS is 4kb that means if a file of 20kb is to be stored, the file will be spread across 5 cluster which sill causes the read/write of the hard drive to spin round to retrieve this single file from the various clusters. What in a case where the size of the file to save is smaller than a the size of a cluster or a little bigger? What will happen in the first case is a full cluster will be used to store the file and in the remaining space of the cluster nothing can be saved on it any more rather a new cluster will be picked even if the remaining size is equal to the file size to save. In the second case two clusters will be used and the remaining space on the second cluster will be a waste because no other file can go in anymore.

This are the problems associated with file system. To solve the problem of fragmentation, Microsoft bundled a utility known as file defragmenter along with windows to help bring fragmented files together.

Post a Comment

0Comments

Post a Comment (0)