智能测试正常时,zfs 反复出现读写错误

智能测试正常时,zfs 反复出现读写错误

我在 Ubuntu 22.04 上使用 OpenZFS 2.1.5。

zpool status -v展示复发性我的一个机械驱动器出现读写错误。但是,SMART 测试未显示磁盘存在任何问题。所谓反复出现的意思是,即使执行了多次清理,错误仍然连续几天增加。

进行长时间的测试后,smartctl -a /dev/sdi给出以下输出:

smartctl 7.2 2020-12-30 r5155 [x86_64-linux-5.15.0-71-generic] (local build)
Copyright (C) 2002-20, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Seagate IronWolf
Device Model:     ST8000VN004-2M2101
Serial Number:    WSD5CNQY
LU WWN Device Id: 5 000c50 0e395c73b
Firmware Version: SC60
User Capacity:    8,001,563,222,016 bytes [8.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:   ACS-4 (minor revision not indicated)
SATA Version is:  SATA 3.3, 6.0 Gb/s (current: 1.5 Gb/s)
Local Time is:    Sat May 20 09:41:56 2023 UTC
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:        (  559) 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:    ( 710) minutes.
Conveyance self-test routine
recommended polling time:    (   2) minutes.
SCT capabilities:          (0x50bd) SCT Status supported.
                    SCT Error Recovery Control supported.
                    SCT Feature Control supported.
                    SCT Data Table 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   081   064   044    Pre-fail  Always       -       115024985
  3 Spin_Up_Time            0x0003   097   078   000    Pre-fail  Always       -       0
  4 Start_Stop_Count        0x0032   048   048   020    Old_age   Always       -       53805
  5 Reallocated_Sector_Ct   0x0033   100   100   010    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x000f   085   060   045    Pre-fail  Always       -       284588125
  9 Power_On_Hours          0x0032   093   093   000    Old_age   Always       -       6371
 10 Spin_Retry_Count        0x0013   100   100   097    Pre-fail  Always       -       0
 12 Power_Cycle_Count       0x0032   048   048   020    Old_age   Always       -       54171
 18 Head_Health             0x000b   100   100   050    Pre-fail  Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   100   000    Old_age   Always       -       1
190 Airflow_Temperature_Cel 0x0022   065   039   040    Old_age   Always   In_the_past 35 (0 54 35 34 0)
192 Power-Off_Retract_Count 0x0032   074   074   000    Old_age   Always       -       53631
193 Load_Cycle_Count        0x0032   069   069   000    Old_age   Always       -       63782
194 Temperature_Celsius     0x0022   035   061   000    Old_age   Always       -       35 (0 19 0 0 0)
195 Hardware_ECC_Recovered  0x001a   081   064   000    Old_age   Always       -       115024985
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      -       2936 (169 98 0)
241 Total_LBAs_Written      0x0000   100   253   000    Old_age   Offline      -       15091623608
242 Total_LBAs_Read         0x0000   100   253   000    Old_age   Offline      -       199570567296

SMART Error Log Version: 1
No Errors Logged

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%      6283         -

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.

以下是与此错误之一相对应的 zfs 事件:

May 20 2023 08:43:08.675217723 ereport.fs.zfs.io
        class = "ereport.fs.zfs.io"
        ena = 0x4e2f19a0af71fc01
        detector = (embedded nvlist)
                version = 0x0
                scheme = "zfs"
                pool = 0x22e98240f9179f3d
                vdev = 0xdc247207eae1c346
        (end detector)
        pool = "zpanier"
        pool_guid = 0x22e98240f9179f3d
        pool_state = 0x0
        pool_context = 0x0
        pool_failmode = "wait"
        vdev_guid = 0xdc247207eae1c346
        vdev_type = "disk"
        vdev_path = "/dev/sdi1"
        vdev_ashift = 0x9
        vdev_complete_ts = 0x454e2f190abaf
        vdev_delta_ts = 0xf22e2
        vdev_read_errors = 0x43
        vdev_write_errors = 0x2
        vdev_cksum_errors = 0x0
        vdev_delays = 0x0
        parent_guid = 0xd9ce168f4fdd4616
        parent_type = "raidz"
        vdev_spare_paths = 
        vdev_spare_guids = 
        zio_err = 0x5
        zio_flags = 0x180880
        zio_stage = 0x1000000
        zio_pipeline = 0x1080000
        zio_delay = 0x334ef7959
        zio_timestamp = 0x454dfb70bd179
        zio_delta = 0x334ef8ae4
        zio_priority = 0x0
        zio_offset = 0x516e48e8000
        zio_size = 0x1000
        zio_objset = 0x490
        zio_object = 0x41310c0
        zio_level = 0x0
        zio_blkid = 0x1
        time = 0x6468881c 0x283f013b 
        eid = 0x8922ee

这个池已经运行了一年半多,没有出现问题。

我是否应该假设 zfs 报告的错误表明磁盘存在问题,但 SMART 数据尚未反映该问题?我应该立即更换磁盘吗?

答案1

经过进一步调查,问题似乎出在我的 SAS 电缆上。

相关内容