LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 11-05-2017, 03:09 PM   #1
hortageno
Member
 
Registered: Aug 2015
Distribution: Ubuntu 22.04 LTS
Posts: 240

Rep: Reputation: 67
Did bad sectors disappear?


Hi,

smartmontools reported

Code:
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       1
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       1
I don't recall what the value of Reallocated_Sector_Ct was, but I think it was 0.

I currently run a extended self test with smartmontools, which has still 70% to go after a few hours. In the meantime I ran badblocks, which reported 4 bad blocks at around 99% of the test at 4 consecutive blocks 236723952 - 236723955.

Code:
fdisk -lu /dev/sde
Disk /dev/sde: 232.9 GiB, 250059350016 bytes, 488397168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x6868a76b

Device     Boot     Start       End   Sectors   Size Id Type
/dev/sde1  *         2046 488396799 488394754 232.9G  5 Extended
/dev/sde5       472772608 488396799  15624192   7.5G 82 Linux swap / Solaris
/dev/sde6            2048 472772607 472770560 225.4G 83 Linux

Partition table entries are not in disk order.
I'm a bit confused how to translate this. Is the output of badblocks the same as the "LBA of first error" of smartmontools? Since the errors happened at ~99% of the test I would have thought the problem lies in the swap partition at the end of the disk. To be on the safe side I checked the whole space in both partitions.


sde6 has a btrfs filesystem, so I can't run debugfs. I ran

Code:
btrfs scrub start -Bd /dev/sde6
which didn't report any errors. Then I filled the free space in sde6 and the complete swap partition with zeroes. Now the Current_Pending_Sector and Offline_Uncorrectable went down to 0 and the Reallocated_Sector_Ct is (still?) 0 too. Syslog also says

Code:
Nov  5 20:08:14 server smartd[842]: Device: /dev/sde [SAT], No more Currently unreadable (pending) sectors, warning condition reset after 4 emails
Nov  5 20:08:14 server smartd[842]: Device: /dev/sde [SAT], No more Offline uncorrectable sectors, warning condition reset after 4 emails
Did the bad sectors/blocks just disappear?
 
Old 11-05-2017, 03:14 PM   #2
rknichols
Senior Member
 
Registered: Aug 2009
Distribution: Rocky Linux
Posts: 4,783

Rep: Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214Reputation: 2214
If the bad sector is rewritten successfully, then it will indeed "just disappear".
 
1 members found this post helpful.
Old 11-06-2017, 12:53 AM   #3
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,930

Rep: Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321Reputation: 7321
I would try to check it later again. I'm not really sure if those sectors are stable enough.
 
1 members found this post helpful.
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Check Hard drive for bad sectors or bad blocks in linux LXer Syndicated Linux News 0 08-11-2014 08:00 AM
LXer: Check Hard drive for bad sectors or bad blocks in linux LXer Syndicated Linux News 0 08-10-2014 12:21 AM
re-allocated sectors count shows 2 bad sectors, in Ubuntu 10.04 disk utility james2b Linux - Hardware 4 10-12-2010 11:16 PM
Bad sectors, what to do with them? SuperDude123 Linux - Hardware 4 02-15-2009 07:36 PM
Bad sectors tuxombie Linux - Hardware 3 01-29-2005 01:05 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 12:10 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration