unhandled error code result hostbyte=did_bad_target driverbyte=driver_ok

If you see this kind of error and something like “sd 0:0:0:0: [sda] Unhandled error code” in your dmesg output. it means its something wrong with your sata device port and you should reset ad re-scan it.

Also it means your linux system don’t see that device and you can’t use it.  This problem can occurs when you are trying to replace bad  disk in RAID array.

readlink /sys/block/sda

echo 1 > /sys/block/sda/device/delete

echo “- – -” > /sys/class/scsi_host/host1/scan

Now you can add your sda, also you can try other sata port if its available.

 

Leave a Reply

Your email address will not be published. Required fields are marked *