Difference between revisions of "Bad Block Howto"
Line 1: | Line 1: | ||
+ | = Your hard disk fails on Linux - now what? = | ||
+ | I happened to me a few times in the last few weeks. A filesystem check for a hard disk would take for ever - my system won't boot. One of the harddisk was reporting errors. | ||
+ | At this time i have four different hard disks that are giving me trouble. | ||
+ | All broken harddisks have been taken out of the system and I am analyzing the problem using a virtual machine and a USB-SATA bridge. | ||
+ | = First step: remove harddisk from system = | ||
+ | Hopefully your disk is not needed to boot or fully operate your system. In that case you might want to boot of a USB stick or other media. In any case my procedure is to remove | ||
+ | the disk from the original system and use a different system for analysis. In my case i am using an Ubuntu based virtual machine and connect the drive via a USB-SATA bridge. | ||
+ | With USB 2 devices the performance is poor. I am not using my old Logilink QP002 Sata Docking Station anymore for this reason. | ||
+ | |||
+ | The USB 3 device i bought in 2015: | ||
+ | https://images-na.ssl-images-amazon.com/images/I/611EMR%2BPqWL._AC_SL1001_.jpg | ||
+ | still serves me well. | ||
+ | |||
= Links = | = Links = | ||
* https://www.smartmontools.org/wiki/BadBlockHowto | * https://www.smartmontools.org/wiki/BadBlockHowto |
Revision as of 09:44, 5 October 2020
Your hard disk fails on Linux - now what?
I happened to me a few times in the last few weeks. A filesystem check for a hard disk would take for ever - my system won't boot. One of the harddisk was reporting errors. At this time i have four different hard disks that are giving me trouble. All broken harddisks have been taken out of the system and I am analyzing the problem using a virtual machine and a USB-SATA bridge.
First step: remove harddisk from system
Hopefully your disk is not needed to boot or fully operate your system. In that case you might want to boot of a USB stick or other media. In any case my procedure is to remove the disk from the original system and use a different system for analysis. In my case i am using an Ubuntu based virtual machine and connect the drive via a USB-SATA bridge. With USB 2 devices the performance is poor. I am not using my old Logilink QP002 Sata Docking Station anymore for this reason.
The USB 3 device i bought in 2015: still serves me well.
Links
- https://www.smartmontools.org/wiki/BadBlockHowto
- https://github.com/hradec/fix_smart_last_bad_sector
- http://dcere.com/hardware/2016/09/18/hard-disk.html
- https://serverfault.com/questions/461203/how-to-use-hdparm-to-fix-a-pending-sector
- https://serverfault.com/a/641135/162693
- https://linux.die.net/man/8/smartctl