S.M.A.R.T. info

RouterOS 中的 S.M.A.R.T. 磁盘健康监控:使用 /disk smart-info 命令读取磁盘健康、温度、使用量与错误计数器,并了解所报告属性的含义。

S.M.A.R.T. 信息

S.M.A.R.T. 信息 CLI 参考

S.M.A.R.T.(Self-Monitoring, Analysis and Reporting Technology,自我监控、分析与报告技术)是现代存储磁盘内置的监控系统。它可让你读取磁盘诊断信息:总体健康、温度、使用量、错误计数器,以及 NVMe 磁盘的 SMART/Health 属性。

信息

S.M.A.R.T. 信息需要 Storage 软件包。 对于任何支持 S.M.A.R.T. 的已连接存储设备,可使用 /disk/smart-info 命令读取诊断信息:

[admin@MikroTik] > /disk/smart-info nvme1
[admin@R2DUTRDS22162XG4S4XS2XQ20DISKS] > disk/smart-info nvme1
Columns: OUTPUT
OUTPUT                                                                     
smartctl 7.1 2019-12-30 r5022 [aarch64-linux-5.6.3] (local build)          
Copyright (C) 2002-19, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF INFORMATION SECTION ===                                       
Model Number:                       U.2 SSD 4TG2-P                         
Serial Number:                      <S/N>                      
Firmware Version:                   E21T4C                                 
PCI Vendor/Subsystem ID:            0x1bc0                                 
IEEE OUI Identifier:                0x24693e                               
Controller ID:                      0                                      
Number of Namespaces:               1                                      
Namespace 1 Size/Capacity:          960,197,124,096 [960 GB]               
Namespace 1 Formatted LBA Size:     512                                    
Namespace 1 IEEE EUI-64:            <EUI-64>                  
Firmware Updates (0x02):            1 Slot                                 
Optional Admin Commands (0x0017):   Security Format Frmw_DL Self_Test      
Optional NVM Commands (0x0054):     DS_Mngmt Sav/Sel_Feat Timestmp         
Maximum Data Transfer Size:         512 Pages                              
Warning  Comp. Temp. Threshold:     100 Celsius                            
Critical Comp. Temp. Threshold:     110 Celsius                            
Supported Power States                                                     
St Op     Max   Active     Idle   RL RT WL WT  Ent_Lat  Ex_Lat             
 0 +    20.00W       -        -    0  0  0  0        5       5             
Supported LBA Sizes (NSID 0x1)                                             
Id Fmt  Data  Metadt  Rel_Perf                                             
 0 +     512       0         0                                             
=== START OF SMART DATA SECTION ===                                        
SMART overall-health self-assessment test result: PASSED                   
SMART/Health Information (NVMe Log 0x02)                                   
Critical Warning:                   0x00                                   
Temperature:                        33 Celsius                             
Available Spare:                    100%                                   
Available Spare Threshold:          10%                                    
Percentage Used:                    0%                                     
Data Units Read:                    5,774,165 [2.95 TB]                    
Data Units Written:                 10,770,860 [5.51 TB]                   
Host Read Commands:                 75,868,764                             
Host Write Commands:                61,379,337                             
Controller Busy Time:               22                                     
Power Cycles:                       579                                    
Power On Hours:                     4,203                                  
Unsafe Shutdowns:                   105                                    
Media and Data Integrity Errors:    0                                      
Error Information Log Entries:      0                                      
Warning  Comp. Temperature Time:    0                                      
Critical Comp. Temperature Time:    0                                      
Temperature Sensor 1:               45 Celsius                             
Temperature Sensor 2:               33 Celsius                             
Temperature Sensor 3:               33 Celsius                             
Temperature Sensor 4:               34 Celsius                             
Temperature Sensor 5:               34 Celsius                             
Temperature Sensor 6:               35 Celsius                             
Temperature Sensor 7:               32 Celsius                             
Temperature Sensor 8:               31 Celsius                             
Error Information (NVMe Log 0x01, max 64 entries)                          
No Errors Logged      

解读输出

磁盘健康的关键数值:

  • SMART overall-health self-assessment test result:磁盘报告自身是否健康。报告 FAILED 的磁盘应更换。
  • Temperature:磁盘当前温度。警告与严重阈值列在信息部分。
  • Available Spare:磁盘在无法重映射坏块之前剩余的备用容量。当其降至 Available Spare Threshold 时,磁盘已接近寿命终点。
  • Percentage Used:基于厂商标称耐久度估算的磁盘寿命使用比例。达到 100% 时,磁盘已达到标称寿命。
  • Unsafe Shutdowns 与 Media and Data Integrity Errors:磁盘意外断电的次数以及检测到的数据错误数量。反复发生不安全关机(unsafe shutdowns)会增加数据损坏风险。

输出与 Linux 上 smartctl 报告一致,因此磁盘厂商的 S.M.A.R.T. 文档同样适用。

说明

某些 USB 硬盘盒无法透传 S.M.A.R.T. 信息。如果磁盘位于此类硬盘盒后方,即使磁盘本身支持 S.M.A.R.T.,/disk/smart-info 也会报告错误。

相关主题

  • 磁盘:格式化、挂载与管理磁盘。