Saturday, May 4, 2024
4
rated 0 times [  4] [ 0]  / answers: 1 / hits: 2436  / 1 Year ago, sat, january 7, 2023, 1:30:27

During the last month Ubuntu starts having some problems: it shuts down suddenly without any apparent reason.. I figured out that the problem is in the hard disk, if I run this command:



$ sudo badblocks -sv -b 512 /dev/sda


I get 24 bad blocks all in the Linux partition (I have Windows in another one and it does not have the same problem). The question is if there is a way (different from changing the disk) for avoiding this shutting down. Maybe isolating the bad blocks?


More From » partitioning

 Answers
6

If a disk has bad sectors (that is what bad blocks detects) then it will still work. Hard disks have extra sectors on them that are automatically remapped so the disk will continue to work.



In Ubuntu you can use Disks (in older versions is was call Disk Utility) to check on the SMART status of the disk. It can give predictive failure information.



Using a utility like SpinRite you can check the disk and definitely find out if they are bad or not. If run at the highest level it will check every sector and reinstate any sectors that are marked bad when they are actually okay, and mark any that should be bad.



If the disk is on the way out I would replace it rather than take any chances.


[#27275] Sunday, January 8, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
serveeel

Total Points: 347
Total Questions: 106
Total Answers: 117

Location: American Samoa
Member since Fri, Aug 26, 2022
2 Years ago
serveeel questions
;