Friday, May 3, 2024
 Popular · Latest · Hot · Upcoming
134
rated 0 times [  134] [ 0]  / answers: 1 / hits: 780314  / 1 Year ago, thu, march 30, 2023, 10:41:26

I suspect there might be bad sector on a disk. I used ext3 filesystem.



What tool is the best equivalent of the error checking tool of Windows?


More From » disk

 Answers
4

Disks



To check for bad sectors check the SMART data, probably the best accessible by launching the Disks utility (Palimpsest). Even if you don't see any bad blocks there, launch a self-test to be sure.



The program is bundled in the gnome-disk-utility package. Run gksudo gnome-disks



SMART from Palimpsest



Or in Ubuntu 16.04 version (3.18):



SMART from Disks



Badblocks



You can also use badblocks



sudo badblocks -sv /dev/sda


to just check, or to check and fix first write the result to a temporary file:



sudo badblocks -sv /dev/sda  > bad-blocks-result
sudo fsck -t ext4 -l bad-blocks-result /dev/sda1


will check the whole disk and print out all bad blocks encountered on /dev/sda.



From badblocks manual:




Important note: If the output of badblocks is going to be fed to the e2fsck or mke2fs programs, it is important that the block size is properly specified, since the block numbers which are generated are very dependent on the block size in use by the filesystem. For this reason, it is strongly recommended that users not run badblocks directly, but rather use the -c option of the e2fsck and mke2fs programs.




fsck



fsck itself will not help you find bad sectors, worse still, if there are a lot of bad sectors it can damage your data even more. Use it only when the disk is healthy.


[#43694] Friday, March 31, 2023, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
corsee

Total Points: 479
Total Questions: 122
Total Answers: 106

Location: Barbados
Member since Sat, May 9, 2020
4 Years ago
;