On Linux disk repair e2fsck command

Source: Internet
Author: User

Linux under Disk Check Repair command e2fsck

-A: Check the partition, and automatically fix the problem if it is found.
-B: Sets the superblock position.
-B Size: Specifies size as a chunk.
C: Check if the partition has a bad track.
-C File: Stores the results of the check in file.
-D: Output e2fsck debug results.
-f:e2fsck presets will only check for the wrong file system, plus-f is a mandatory check.
-F: Erase the drive's buffer cache before checking to avoid errors.
-l list: The bad rail block is logged into the list.
-D: Prints the debug results of the e2fsck.
-F: Mandatory check.
-N: Open the file system (READ-ONLY)
-P: Turn off interactive mode, if there is a problem with automatic repair, equivalent to-a.
-V: Displays a detailed report.
-Y: Enable user interaction mode.

Examples of Use

Check the/dev/mapper/volgroup00-logvol02 for problems and fix them automatically if they are found:

E2fsck-a/dev/mapper/volgroup00-logvol02

Please umount partition before executing e2fsck or fsck, otherwise the file system will be destroyed.

If the partition is busy, all processes involved in the partition need to be killed, and a quick way is to execute fuser-k/home.

If the root directory (/) needs to be checked and repaired, it needs to go into Singal user mode.

Finally, don't forget to put the partition on Mount.


On Linux disk repair e2fsck command

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.