e2fsck is used to check a Linux second extended file system.

device The special file corresponding to the device (such as /dev/hdXX).


-b superblock -B blocksize

-l fi lename -L fi lename

This option does the same thing as the -p option. It is provided for backwards compatibility only; it is suggested that people use -p option whenever possible. Instead of using the normal superblock, use the alternative superblock specified by superblock.

Usually, e2fsck will search for the superblock at various different block sizes in an attempt to find the appropriate block size. This search can be fooled in some cases. This option forces e2fsck to only try locating the superblock at a particular blocksize. If the superblock is not found, e2fsck will terminate with a fatal error. Print debugging output (useless unless you are debugging e2fsck ). Force checking even if the filesystem seems clean.

Flush the filesystem device's buffer caches before beginning. Only really useful for doing e2fsck time trials.

Add the blocks listed in the file specified by filename to the list of bad blocks. Set the bad blocks list to be the list of blocks specified by fil ename. (This option is the same as the -l option except the bad blocks list is cleared before the blocks listed in the file are added to the bad blocks list.)

Open the filesystem read-only, and assume an answer of "no" to all questions. Allows e2fsck to be used non-interactively. (Note: if the -l or -L options are specified in addition to the -n option, then the filesystem will be opened read-write to permit the bad-blocks list to be updated. However, no other changes will be made to the filesystem.)

Automatically repair ("preen") the filesystem without any questions. This option does nothing at all; it is provided only for backwards compatibility. Print timing statistics for e2fsck. If this option is used twice, additional timing statistics are printed on a pass-by-pass basis. Verbose mode.

Print version information and exit.

Assume an answer of "yes" to all questions; allows e2fsck to be used non-interactively.

Was this article helpful?

0 0

Post a comment