Have you ever got error messages in Windows / Linux, similar to these ?
ata1: soft resetting link
ata1: link is slow to respond, please be patient
Buffer I/O error on device sda, logical block 0
ata1: device not ready (errno=-16), forcing hardreset
[sda] Result: hostbyte=DID_BAD_TARGET driverbyte=DRIVER_OK
end_request: I/O error, dev sdb, sector 0
ata1: SRST failed
ata1.00: exception Emask 0x0 SAct
Usually the first thing that came to my thought was “damn, the hard disk is toast” 🙂
Turned out, in many cases, it’s NOT so. The hard disk is actually is still okay.
It’s just not set up right !
Thankfully, we can fix this very easily in Linux.
One / several of the following kernel parameters listed below may fix the problem we encountered above :
If you don’t know which is the right one, it should be quite safe to try them one by one.
In my most recent case, point #1 solved the problem.
Turned out the motherboard (not the hard disk) is not very reliable, so we need to turn off DMA. Usually, this can be done via the BIOS. Imagine my surprise when I found that the BIOS is very, Very sparse ! It’s almost impossible to set anything.
Thanks to Linux, I was still able to disable DMA, via said kernel parameter instead (libata.dma=0)
The computer is now performing flawlessly. 🙂
“Waiiiiit a minute – how do I set the kernel parameter ??”
Good question. Follow these steps if you’re using Ubuntu Linux :
- Open the Terminal (Application – Accessories – Terminal)
- type : sudo nano /etc/default/grub
- Look for the following line : GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash”
- Add the kernel parameter(s) that you may need. Example : GRUB_CMDLINE_LINUX_DEFAULT=”quiet libata.dma=0 splash”
- Press Ctrl – O to save the change, then press Ctrl – X to quit the nano editor.
- Now we need to update the boot manager. Type : sudo update-grub
- Done ! On the next restart, the kernel parameter will come into effect.
Still experiencing problems ?
Remember, the hard disk is just a component in the PC. Although the error messages came from the hard disk – the actual problem can reside elsewhere along the data pipeline.
For example, once I was troubleshooting an unreliable hard disk. Turned out the culprit was the IDE cable ! Once replaced, everything went alright.
So in case of hard disk related problems, here are some things that you can try first :
- Fasten the cables.
- Replace the cables.
- Try a different SATA / hard disk port on the motherboard.
- Make sure that the power supply actually provides enough power for all of the components in the PC.
Have tried all the above, but still experiencing problem with the hard disk ? Then you can be more certain that indeed now the culprit is the hard disk itself 🙂 and not some other things instead.
Hope this post will have saved you a hard disk / SSD drive. Happy troubleshooting ! 🙂