So, lately I've been having issues booting up Ubuntu and having to go into grub and do a recovery boot and I'll have issues saying "i/o errors in dev/sda" or something along those lines and I noticed I have 113 have bad sectors in my HDD when I just recently started the Disks setting. Isn't there a way to block out those bad sectors or something? What should I do? Thank you!
Asked
Active
Viewed 2.0k times
1 Answers
9
With bad sectors, you should always immediately backup all important information and get a new hard drive. You can theoretically mark these sectors as "bad" and tell the computer not to use them. However, this is not at all recommended as bad sectors like spreading like a fungus.
If you want to try this, instructions are below.
- Find your hard drive with
lsblk. Find the EXT partition mounted at/. - Remember the code. It should look something like
/dev/sda1. - Strip the number off the code you got earlier. If you had
/dev/sda1, your code is now/dev/sda. - Run this command:
sudo badblocks /dev/sdc > /home/$USER/bad-blocks - Run this command:
sudo fsck -l bad-blocks /dev/sdc - While running the above commands, go take a walk. Do not touch your computer.
Disclaimer: I am not responsible for any loss of data or system damage that has resulted from the above commands, both instant and in the future. I hold no responsibility for what you type into your terminal. You have been warned.
Kaz Wolfe
- 34,680