在TrueNAS/FreeBSD上定位故障硬盘槽位

刚做好一个NAS,利用TrueNAS做的,结果一直报da5有故障

Aug 21 23:21:30 truenas 1 2021-08-21T23:21:30.808165-07:00 truenas.local smartd 1421 - - Device: /dev/da5 [SAT], 624 Offline uncorrectable sectors
Aug 21 23:51:30 truenas 1 2021-08-21T23:51:30.506395-07:00 truenas.local smartd 1421 - - Device: /dev/da5 [SAT], 624 Currently unreadable (pending) sectors

这里分享一下查找故障硬盘的方法。

1、对SN

如果NAS可以关机,那么可以通过SN,来一块一块硬盘对应。这是最有效的方法,也是最安全的方法。在web页面的硬盘里,找到故障硬盘的SN

2、通过工具去确认槽位.

TrueNAS集成了绝大部分的磁盘控制器管理软件

如:sas2ircu、sas3ircu、hptraidconf、storcli。

因为我这里用的是SAS2008的直通卡,所以使用sas2ircu。

1、查看磁盘控制器列表

root@truenas[~]# sas2ircu list
LSI Corporation SAS2 IR Configuration Utility.
Version 20.00.00.00 (2014.09.18)
Copyright (c) 2008-2014 LSI Corporation. All rights reserved.


         Adapter      Vendor  Device                       SubSys  SubSys
 Index    Type          ID      ID    Pci Address          Ven ID  Dev ID
 -----  ------------  ------  ------  -----------------    ------  ------
   0     SAS2008     1000h    72h   00h:01h:00h:00h      1734h   1177h

2、查看磁盘控制器的硬盘

root@truenas[~]# sas2ircu 0 display
LSI Corporation SAS2 IR Configuration Utility.
Version 20.00.00.00 (2014.09.18)
Copyright (c) 2008-2014 LSI Corporation. All rights reserved.

Read configuration has been initiated for controller 0
------------------------------------------------------------------------
Controller information
------------------------------------------------------------------------
  Controller type                         : SAS2008
  BIOS version                            : 7.39.02.00
  Firmware version                        : 20.00.07.00
  Channel description                     : 1 Serial Attached SCSI
  Initiator ID                            : 0
  Maximum physical devices                : 255
  Concurrent commands supported           : 3432
  Slot                                    : 3
  Segment                                 : 0
  Bus                                     : 1
  Device                                  : 0
  Function                                : 0
  RAID Support                            : No
------------------------------------------------------------------------
IR Volume information
------------------------------------------------------------------------
------------------------------------------------------------------------
Physical device information
------------------------------------------------------------------------
Initiator at ID #0

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 0
  SAS Address                             : 5000c50-0-8428-6a8d
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : SEAGATE
  Model Number                            : ST4000NM0023
  Firmware Revision                       : 0004
  Serial No                               : Z1Z9HGM8
  GUID                                    : N/A
  Protocol                                : SAS
  Drive Type                              : SAS_HDD

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 1
  SAS Address                             : 5000c50-0-8428-ea61
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : SEAGATE
  Model Number                            : ST4000NM0023
  Firmware Revision                       : 0004
  Serial No                               : Z1Z9J1LW
  GUID                                    : N/A
  Protocol                                : SAS
  Drive Type                              : SAS_HDD

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 2
  SAS Address                             : 5000c50-0-8428-fc29
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : SEAGATE
  Model Number                            : ST4000NM0023
  Firmware Revision                       : 0004
  Serial No                               : Z1Z9J10Z
  GUID                                    : N/A
  Protocol                                : SAS
  Drive Type                              : SAS_HDD

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 3
  SAS Address                             : 5000c50-0-8f5b-e3c9
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : SEAGATE
  Model Number                            : ST4000NM0023
  Firmware Revision                       : 0004
  Serial No                               : S1Z1K8X3
  GUID                                    : N/A
  Protocol                                : SAS
  Drive Type                              : SAS_HDD

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 5
  SAS Address                             : 4433221-1-0600-0000
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : ATA
  Model Number                            : ST4000NM0033-9ZM
  Firmware Revision                       : SN06
  Serial No                               : Z1ZBFXRT
  GUID                                    : N/A
  Protocol                                : SATA
  Drive Type                              : SATA_HDD

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 6
  SAS Address                             : 5000c50-0-946d-b60d
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : SEAGATE
  Model Number                            : ST4000NM0125
  Firmware Revision                       : E004
  Serial No                               : ZC132037
  GUID                                    : N/A
  Protocol                                : SAS
  Drive Type                              : SAS_HDD

Device is a Hard disk
  Enclosure #                             : 1
  Slot #                                  : 7
  SAS Address                             : 4433221-1-0400-0000
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : ATA
  Model Number                            : ST4000NM0033-9ZM
  Firmware Revision                       : SN06
  Serial No                               : Z1ZBG0SR
  GUID                                    : N/A
  Protocol                                : SATA
  Drive Type                              : SATA_HDD
------------------------------------------------------------------------
Enclosure information
------------------------------------------------------------------------
  Enclosure#                              : 1
  Logical ID                              : 50030057:00c81220
  Numslots                                : 8
  StartSlot                               : 0
------------------------------------------------------------------------
SAS2IRCU: Command DISPLAY Completed Successfully.
SAS2IRCU: Utility Completed Successfully.

太长了,用grep吧

root@truenas[~]# sas2ircu 0 display |grep  -B 8 Z1ZBG0SR
  Enclosure #                             : 1
  Slot #                                  : 7
  SAS Address                             : 4433221-1-0400-0000
  State                                   : Ready (RDY)
  Size (in MB)/(in sectors)               : 3815447/7814037167
  Manufacturer                            : ATA
  Model Number                            : ST4000NM0033-9ZM
  Firmware Revision                       : SN06
  Serial No                               : Z1ZBG0SR

通过上述输出可以看到硬盘SN:Z1ZBG0SR对应的槽位是
Enclosure # : 1,Slot # : 7

那么可以先将此硬盘下线,在背板拔除此硬盘即可。

版权声明:
作者:佛西
链接:https://foxi.buduanwang.vip/yj/1312.html/
文章版权归作者所有,未经允许请勿转载
如需获得支持,请点击网页右上角
THE END
分享
二维码
海报
在TrueNAS/FreeBSD上定位故障硬盘槽位
刚做好一个NAS,利用TrueNAS做的,结果一直报da5有故障 Aug 21 23:21:30 truenas 1 2021-08-21T23:21:30.808165-07:00 truenas.local smartd 1421 - - Dev……
<<上一篇
下一篇>>