Linux disk bad track detection and repair

Source: Internet
Author: User

    1. uses DMESG checks for information about disk errors, and is sure to find a large number of disk sector errors, as follows:   end_request:   I/O error, Dev 03:06 (SDA), Sector  
    2. from the above output we may have a problem with the sector, using badblocks-s-v-o/root/badblocks.log/dev/sda   Check to see if the hard drive is producing bad lanes and outputting to Badblocks.log. The log is about this pattern:64039224 64039240 64039241 64039242 64039243 64039256 64039257  64039258 64039259 687056
    3. fixes for repairing bad ways: 1 using  badblocks-s-W  /DEV/SDA end START END Represents the end of the sector that needs to be repaired, and start represents the starting end of the sector that needs to be repaired. 2 using fsck-a/dev/sda1
There are three types of broken disks: 0 Tracks bad, logical bad, hard drive bad. The logical bad way can be repaired using the above method, the 0 track bad track repair method is to isolate 0 tracks, using the Fdsk partition area from the 1 tracks began to partition. If the hard drive is bad, it can only be isolated and cannot be repaired. Hard drive Bad Path monitoring method: Use the above method to detect the repair, and then useBadblocks-s-v-o/ROOT/BADBLOCKS.LOG/DEV/SDA monitoring to see if there is still a bad way, if the bad word or existence, it means bad road belongs to the hard drive bad. Hard drive Bad Channel isolation method, first record the detected hard drive bad channel, and then partition the hard drive when the bad path is located in a partition (the size is generally greater than the bad sector size), divided the bad channel partition is not used to achieve the purpose of isolation. Isolation is only a temporary solution, it is recommended to replace the hard disk as soon as possible, because the bad channel will spread to avoid serious data problems later. Reprinted from: http://blog.chinaunix.net/uid-20786165-id-3170784.html
Related Article

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.