Open In App

File System Consistency Checker (FSCK)

File system inconsistency is a major issue in operating systems. FSCK is one of the standard solutions adopted.

File System Consistency Checker (FSCK):
FSCK is one approach still used by older Linux-based systems to find and repair inconsistencies. It is not a complete solution and may still have inodes pointing to garbage data. The major focus is to make the metadata internally consistent.



The following are the checks that FSCK performs to achieve consistency:

Advantages of FSCK:



Disadvantages of FSCK:

fsck Command in Linux:
The fsck command in Linux allows us to manually check for file system inconsistencies. Below is the sample usage of the command.

sudo fsck /dev/sda2

The above command simply checks the file system mounted onto the /dev/sda2 partition. If the file system may have some inconsistencies, fsck prompts us with possible actions.

fsck.fat 4.1 (2017-01-24) 

0x41: Dirty bit is set. Fs was not properly unmounted and some data may be corrupt: Remove dirty bit, and No action.

Article Tags :