Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

Linux e2fsck command

Linux e2fsck command

Linux Command Reference Linux Command Reference

The Linux e2fsck command is used to check whether a partition using the Linux ext2 file system is working properly.

Syntax



e2fsck [-pacnydfvFV] [-b superblock] [-B blocksize] [-l|-L bad_blocks_file] [-C fd] device

Parameter Description:

Example

Check whether /dev/hda5 is normal; if there are errors, repair them automatically, and set all questions to be answered [yes]:

e2fsck -a -y /dev/hda5

**Note **:

In most cases, using e2fsck to check a hard disk partition involves special circumstances, so it is best to unmount the partition first and then run e2fsck to check it. If you must check /, enter single user mode before executing.

Linux Command Reference Linux Command Reference