Check Disk or
chkdsk command is used to detect FAT16, FAT32, NTFS file system related errors and fix them. Chkdsk can not recover corrupted files which are a hard situation. Chkdsk can be run from the command line or from GUI but the command line use is the most practical way.
Syntax of chkdsk is very simple. There is two types of parameters like OPTIONS and VOLUME.
chkdsk OPTIONS VOLUME
- `OPTIONS` is used to specify the behavior of the `chkdsk` command.
- `VOLUME` is the drive, partition or volume we want to operate with the chkdsk command.
Schedule Check Disk At System Start
One of the most popular use case for
chkdsk is scheduling a check at the system startup or restart. Because we can not check system volume which is generally
C: at run time. Before mounting the volume the check operation is done.
> chkdsk /F C:
Fix Errors On Disk
File systems used to store files and folders, user data in an appropriate way. file systems have very complex structure related to their features. Shutdown down a system an unexpected way Halting system, disk related issues may create errors in file systems. We can simply use
/F option with the volume name which is
D: in this example.
> chkdsk /F D:
Locate Bad Sector
Disk drives store data in sectors. Each sector holds some data according to its size configuration. Disk drives can lose some of their sectors in time. This is physical damage so it can not be fixed in a physical way. We can locate and label these sectors as bad sectors and prevent them to be used by the file system. We can do this with
/R option. In this example, we check bad sectors of volume
> chkdsk /R D:
Force Unmount Of Volume, Partition or Disk
While doing disk related operations we need to unmount the volume in order to prevent unexpected errors. Checking mounted volumes and file systems will create conflicts. We can unmount the filesystem and volume before the operation with
> chkdsk /X D:
Fast Check Of Volume, Partition or Disk
Checking of the file system and disk errors may take some time. By default, chkdsk uses very detailed check procedures. But some of them are not necessary in most cases. We can prevent to use unneeded checks to make check faster. We will use
/I /C for checking in a fast way.
> chkdsk /I /C D:
Check Disk In Verbose Manner
Verbose mode provides more detailed information about the current operation. We can get details with
> chkdsk /V D: