All times are UTC - 5 hours [ DST ]




Post new topic Reply to topic  [ 1 post ] 
Author Message
 Post subject: badblocks shows errors but smartctl and vendor util does not
PostPosted: January 31st, 2021, 20:44 
Offline

Joined: January 31st, 2021, 20:36
Posts: 1
Location: Slovakia
Hello

I have external HDD Samsung (inside it is Seagate Baracuda) D3 Station 2TB contaning one NTFS patition. I've successfully cloned whole disk using ddrescue with no errors. From cloned image I can mount NTFS partition and seems that everything is fine except one file:

Code:
root@ryzen:/mnt/SAMSUNG_2TB# du -sh * | sort -h
du: cannot access 'EDU_VIDEOS/coursera/Coursera - Stanford University - Jeff Ulman - Automata/02 - Week 2 Regular Expression and Properties of Regular Languages/03 - 7. Decision algorithms for regular languages (41 min.)/7_rs1.pdf': Input/output error


`dmesg` shows nothing suspicious, except:

Code:
[ 1041.102751] ntfs: driver 2.1.32 [Flags: R/O MODULE].
[ 1041.105653] ntfs: volume version 3.1.
[ 1268.754273] __ntfs_error: 6 callbacks suppressed
[ 1268.754274] ntfs: (device loop0): map_mft_record_page(): Mft record 0x1c52 is corrupt.  Run chkdsk.
[ 1268.754287] ntfs: (device loop0): map_mft_record(): Failed with error code 5.
[ 1268.754292] ntfs: (device loop0): ntfs_read_locked_inode(): Failed with error code -5.  Marking corrupt inode 0x1c52 as bad.  Run chkdsk.


Then I've done smartctl long test with following results:

Code:
root@ryzen:~# smartctl -a -d sat /dev/sdd
smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.4.34-1-pve] (local build)
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Seagate Barracuda 7200.14 (AF)
Device Model:     ST2000DM001-1E6164
Serial Number:    W1E903F0
LU WWN Device Id: 5 000c50 07d3083c7
Firmware Version: SC48
User Capacity:    2,000,398,934,016 bytes [2.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    7200 rpm
Form Factor:      3.5 inches
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ATA8-ACS T13/1699-D revision 4
SATA Version is:  SATA 3.0, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is:    Mon Jan 25 08:53:36 2021 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
See vendor-specific Attribute list for marginal Attributes.

General SMART Values:
Offline data collection status:  (0x00)   Offline data collection activity
               was never started.
               Auto Offline Data Collection: Disabled.
Self-test execution status:      (   0)   The previous self-test routine completed
               without error or no self-test has ever
               been run.
Total time to complete Offline
data collection:       (  584) seconds.
Offline data collection
capabilities:          (0x73) SMART execute Offline immediate.
               Auto Offline data collection on/off support.
               Suspend Offline collection upon new
               command.
               No Offline surface scan supported.
               Self-test supported.
               Conveyance Self-test supported.
               Selective Self-test supported.
SMART capabilities:            (0x0003)   Saves SMART data before entering
               power-saving mode.
               Supports SMART auto save timer.
Error logging capability:        (0x01)   Error logging supported.
               General Purpose Logging supported.
Short self-test routine
recommended polling time:    (   1) minutes.
Extended self-test routine
recommended polling time:    ( 232) minutes.
Conveyance self-test routine
recommended polling time:    (   2) minutes.
SCT capabilities:           (0x3081)   SCT Status supported.

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   113   100   006    Pre-fail  Always       -       54720264
  3 Spin_Up_Time            0x0003   095   095   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   100   100   020    Old_age   Always       -       67
  5 Reallocated_Sector_Ct   0x0033   100   100   010    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   100   253   030    Pre-fail  Always       -       30065584744
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       136
10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       53
183 Runtime_Bad_Block       0x0032   100   100   000    Old_age   Always       -       0
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   001   000    Old_age   Always       -       7 7 65535
189 High_Fly_Writes         0x003a   100   100   000    Old_age   Always       -       0
190 Airflow_Temperature_Cel 0x0022   054   045   045    Old_age   Always   In_the_past 46 (Min/Max 21/53)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       0
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       6
193 Load_Cycle_Count        0x0032   100   100   000    Old_age   Always       -       765
194 Temperature_Celsius     0x0022   046   055   000    Old_age   Always       -       46 (0 20 0 0 0)
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       56h+06m+40.808s
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       846975072
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       4758693957

SMART Error Log Version: 1
ATA Error Count: 2
   CR = Command Register [HEX]
   FR = Features Register [HEX]
   SC = Sector Count Register [HEX]
   SN = Sector Number Register [HEX]
   CL = Cylinder Low Register [HEX]
   CH = Cylinder High Register [HEX]
   DH = Device/Head Register [HEX]
   DC = Device Command Register [HEX]
   ER = Error register [HEX]
   ST = Status register [HEX]
Powered_Up_Time is measured from power on, and printed as
DDd+hh:mm:SS.sss where DD=days, hh=hours, mm=minutes,
SS=sec, and sss=millisec. It "wraps" after 49.710 days.

Error 2 occurred at disk power-on lifetime: 63 hours (2 days + 15 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 00 ff ff ff 4f 00      00:00:12.218  READ DMA EXT
  25 00 08 c0 05 60 40 00      00:00:12.217  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:12.210  READ DMA EXT
  25 00 28 ff ff ff 4f 00      00:00:12.149  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:11.675  READ DMA EXT

Error 1 occurred at disk power-on lifetime: 63 hours (2 days + 15 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 00 ff ff ff 4f 00      00:00:12.218  READ DMA EXT
  25 00 08 c0 05 60 40 00      00:00:12.217  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:12.210  READ DMA EXT
  25 00 28 ff ff ff 4f 00      00:00:12.149  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:11.675  READ DMA EXT

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Extended offline    Completed without error       00%       132         -
# 2  Short offline       Completed without error       00%       126         -
# 3  Extended offline    Aborted by host               90%       126         -
# 4  Short offline       Completed without error       00%       126         -
# 5  Short offline       Aborted by host               70%       126         -
# 6  Short offline       Completed without error       00%       126         -
# 7  Short offline       Completed without error       00%       126         -
# 8  Short offline       Completed without error       00%       106         -

SMART Selective self-test log data structure revision number 1
SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.


As far as I understand above output it all seems fine maybe except this line:
Code:
40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

which is bug in old 2.6 kernel! http://patchwork.ozlabs.org/project/lin ... savvy.com/
and I have no idea how this could happend because I'm using latest kernel.

So after this I've issued badblocks -nsv /dev/sdX -o badblocks.log
After this I got 11GB! log file full of bad blocks and no commands (fdisk, lsblk) was able to access hdd anymore. Oh, and dmesg was full of messages like those:

Code:
[153480.139575] Buffer I/O error on dev sde, logical block 3206647748, async page read
[153480.139684] Buffer I/O error on dev sde, logical block 3206647749, async page read
[153480.139790] Buffer I/O error on dev sde, logical block 3206647750, async page read
[153480.139895] Buffer I/O error on dev sde, logical block 3206647751, async page read
[153480.140004] Buffer I/O error on dev sde, logical block 3206647744, async page read
[153480.140117] Buffer I/O error on dev sde, logical block 3206647745, async page read
[153485.143004] buffer_io_error: 9681598 callbacks suppressed


So after this I've removed disk from case and connected it directly to mainboard via SATA and run again badblocks and smartctl long. The results for badblobcks are narly same as previous: badblocks reports errors bud smartctl does not. Here is output after long test:

Code:
root@ryzen:~# smartctl -a /dev/sda
smartctl 7.1 2019-12-30 r5022 [x86_64-linux-5.4.34-1-pve] (local build)
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Seagate Barracuda 7200.14 (AF)
Device Model:     ST2000DM001-1E6164
Serial Number:    W1E903F0
LU WWN Device Id: 5 000c50 07d3083c7
Firmware Version: SC48
User Capacity:    2,000,398,934,016 bytes [2.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    7200 rpm
Form Factor:      3.5 inches
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ATA8-ACS T13/1699-D revision 4
SATA Version is:  SATA 3.0, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Fri Jan 29 17:38:54 2021 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
See vendor-specific Attribute list for marginal Attributes.

General SMART Values:
Offline data collection status:  (0x82)   Offline data collection activity
               was completed without error.
               Auto Offline Data Collection: Enabled.
Self-test execution status:      (   0)   The previous self-test routine completed
               without error or no self-test has ever
               been run.
Total time to complete Offline
data collection:       (  584) seconds.
Offline data collection
capabilities:           (0x7b) SMART execute Offline immediate.
               Auto Offline data collection on/off support.
               Suspend Offline collection upon new
               command.
               Offline surface scan supported.
               Self-test supported.
               Conveyance Self-test supported.
               Selective Self-test supported.
SMART capabilities:            (0x0003)   Saves SMART data before entering
               power-saving mode.
               Supports SMART auto save timer.
Error logging capability:        (0x01)   Error logging supported.
               General Purpose Logging supported.
Short self-test routine
recommended polling time:     (   1) minutes.
Extended self-test routine
recommended polling time:     ( 232) minutes.
Conveyance self-test routine
recommended polling time:     (   2) minutes.
SCT capabilities:           (0x3081)   SCT Status supported.

SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x000f   116   100   006    Pre-fail  Always       -       106098520
  3 Spin_Up_Time            0x0003   095   095   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   100   100   020    Old_age   Always       -       69
  5 Reallocated_Sector_Ct   0x0033   100   100   010    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   100   253   030    Pre-fail  Always       -       42950569832
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       189
10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
12 Power_Cycle_Count       0x0032   100   100   020    Old_age   Always       -       55
183 Runtime_Bad_Block       0x0032   100   100   000    Old_age   Always       -       0
184 End-to-End_Error        0x0032   100   100   099    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   001   000    Old_age   Always       -       7 7 65535
189 High_Fly_Writes         0x003a   099   099   000    Old_age   Always       -       1
190 Airflow_Temperature_Cel 0x0022   066   045   045    Old_age   Always   In_the_past 34 (Min/Max 34/36)
191 G-Sense_Error_Rate      0x0032   100   100   000    Old_age   Always       -       0
192 Power-Off_Retract_Count 0x0032   100   100   000    Old_age   Always       -       8
193 Load_Cycle_Count        0x0032   100   100   000    Old_age   Always       -       767
194 Temperature_Celsius     0x0022   034   055   000    Old_age   Always       -       34 (0 20 0 0 0)
197 Current_Pending_Sector  0x0012   100   100   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0010   100   100   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x003e   200   200   000    Old_age   Always       -       0
240 Head_Flying_Hours       0x0000   100   253   000    Old_age   Offline      -       67h+06m+11.667s
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       1100316256
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       5016214998

SMART Error Log Version: 1
ATA Error Count: 2
   CR = Command Register [HEX]
   FR = Features Register [HEX]
   SC = Sector Count Register [HEX]
   SN = Sector Number Register [HEX]
   CL = Cylinder Low Register [HEX]
   CH = Cylinder High Register [HEX]
   DH = Device/Head Register [HEX]
   DC = Device Command Register [HEX]
   ER = Error register [HEX]
   ST = Status register [HEX]
Powered_Up_Time is measured from power on, and printed as
DDd+hh:mm:SS.sss where DD=days, hh=hours, mm=minutes,
SS=sec, and sss=millisec. It "wraps" after 49.710 days.

Error 2 occurred at disk power-on lifetime: 63 hours (2 days + 15 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 00 ff ff ff 4f 00      00:00:12.218  READ DMA EXT
  25 00 08 c0 05 60 40 00      00:00:12.217  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:12.210  READ DMA EXT
  25 00 28 ff ff ff 4f 00      00:00:12.149  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:11.675  READ DMA EXT

Error 1 occurred at disk power-on lifetime: 63 hours (2 days + 15 hours)
  When the command that caused the error occurred, the device was active or idle.

  After command completion occurred, registers were:
  ER ST SC SN CL CH DH
  -- -- -- -- -- -- --
  40 51 00 ff ff ff 0f  Error: UNC at LBA = 0x0fffffff = 268435455

  Commands leading to the command that caused the error were:
  CR FR SC SN CL CH DH DC   Powered_Up_Time  Command/Feature_Name
  -- -- -- -- -- -- -- --  ----------------  --------------------
  25 00 00 ff ff ff 4f 00      00:00:12.218  READ DMA EXT
  25 00 08 c0 05 60 40 00      00:00:12.217  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:12.210  READ DMA EXT
  25 00 28 ff ff ff 4f 00      00:00:12.149  READ DMA EXT
  25 00 20 ff ff ff 4f 00      00:00:11.675  READ DMA EXT

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Extended offline    Completed without error       00%       187         -
# 2  Extended offline    Completed without error       00%       132         -
# 3  Short offline       Completed without error       00%       126         -
# 4  Extended offline    Aborted by host               90%       126         -
# 5  Short offline       Completed without error       00%       126         -
# 6  Short offline       Aborted by host               70%       126         -
# 7  Short offline       Completed without error       00%       126         -
# 8  Short offline       Completed without error       00%       126         -
# 9  Short offline       Completed without error       00%       106         -

SMART Selective self-test log data structure revision number 1
SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.


I've tried Long Generic Test under SeaTools Bootable directly from Seagate. This shows no errors.

1. why does badblocks show erros when smartctl and SeaTools Bootable does not?
2. Is my drive dying (it has just few hours powered up as shown in smartctl) or do I have just corrupted FS?
3. is badblocks still relevant on new drives?

Thank you very much


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 22 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group