Article Title: Linux tips: Use the Fsck command to repair damaged partitions. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
Enter the Root password and use fsck-t ext3-r/usr/local to fix the issue.
How to Use the fsck command
Command: fsck
Permission: Super User
Usage: fsck [-sACVRP] [-t fstype] [?] [Fsck-options] filesys […]
Note: Check and repair the Linux File System. You can check one or more Linux file systems at the same time.
Parameters:
Filesys: device Name (eg./dev/sda1), mount point (eg./or/usr)
-T: specifies the type of the file system. This parameter is not required if a definition is already defined in/etc/fstab or is supported by the kernel.
-S: Execute The fsck command one by one in sequence to check
-A: Check the partition of all columns in/etc/fstab.
-C: displays the complete check progress.
-D: print the debug result of e2fsck.
-P: When both-A conditions exist, multiple fsck checks are executed together.
-R: if both-A conditions are available, this parameter is omitted/not checked.
-V: Detailed Display Mode
-A: If the check is incorrect, it will be automatically repaired.
-R: if the check is incorrect, the user will answer whether the problem is fixed.
Example:
Check whether/dev/hda5 of the msdos file system is normal. If an exception exists, it is automatically repaired: fsck-t msdos-a/dev/hda5
Note:
This command can be used with/etc/fstab for reference operations.