Smartctl
Программа под Linux просмотра информации о диске и запуске тестов
Общая оценка состояния диска
Общая оценка вероятности выхода диска из строя в ближайшие 24 часа
smartctl -H /dev/sata1
smartctl 6.5 (build date Sep 26 2022) [x86_64-linux-4.4.302+] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
Список тестов, поддерживаемых диском
Выводит список тестов, которые диск может провести самостоятельно и предполагаемая длительность каждого теста
smartctl -c /dev/sata1
smartctl 6.5 (build date Sep 26 2022) [x86_64-linux-4.4.302+] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF READ SMART DATA SECTION ===
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: ( 575) 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: ( 820) minutes.
Conveyance self-test routine
recommended polling time: ( 2) minutes.
SCT capabilities: (0x70bd) SCT Status supported.
SCT Error Recovery Control supported.
SCT Feature Control supported.
SCT Data Table supported.
А так можно посмотреть список имен тестов для передачи в качестве параметра:
smartctl -t
smartctl 6.5 (build date Sep 26 2022) [x86_64-linux-4.4.302+] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=======> ARGUMENT REQUIRED FOR OPTION: t
=======> VALID ARGUMENTS ARE: offline, short, long, conveyance, force, vendor,N, select,M-N, pending,N, afterselect,[on|off] <=======
Use smartctl -h to get a usage summary
Запуск теста на выполнение
smartctl -d sat -t short /dev/sata1
smartctl 6.5 (build date Sep 26 2022) [x86_64-linux-4.4.302+] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF OFFLINE IMMEDIATE AND SELF-TEST SECTION ===
Sending command: "Execute SMART Short self-test routine immediately in off-line mode".
Drive command "Execute SMART Short self-test routine immediately in off-line mode" successful.
Testing has begun.
Please wait 1 minutes for test to complete.
Test will complete after Sun Apr 7 00:03:54 2024
Use smartctl -X to abort test.
История результатов самотестирования
smartctl -l selftest /dev/sata1
smartctl 6.5 (build date Sep 26 2022) [x86_64-linux-4.4.302+] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF READ SMART DATA SECTION ===
SMART Self-test log structure revision number 1
Num Test_Description Status Remaining LifeTime(hours) LBA_of_first_error
# 1 Short offline Completed without error 00% 7008 -
# 2 Extended offline Interrupted (host reset) 00% 6522 -
# 3 Extended offline Interrupted (host reset) 00% 5145 -
# 4 Extended offline Completed without error 00% 4436 -
# 5 Extended offline Completed without error 00% 3720 -
# 6 Extended offline Completed without error 00% 3002 -
# 7 Extended offline Completed without error 00% 2281 -
# 8 Extended offline Completed without error 00% 1537 -
# 9 Extended offline Completed without error 00% 793 -
#10 Extended offline Completed without error 00% 120 -
#11 Short offline Completed without error 00% 100 -
#12 Extended offline Completed without error 00% 90 -
#13 Extended offline Aborted by host 90% 0 -
#14 Short offline Completed without error 00% 0 -
Вывод полной информации о диске
smartctl -a /dev/sata1
smartctl 6.5 (build date Sep 26 2022) [x86_64-linux-4.4.302+] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF INFORMATION SECTION ===
Model Family: Iron Wolf
Device Model: ABC-DEF
Serial Number: XXXXXXX
LU WWN Device Id: 0 000000 000000000
Firmware Version: ABC03
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-3 T13/2161-D revision 5
SATA Version is: SATA 3.1, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is: Sat Apr 6 23:43:13 2024 MSK
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
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: ( 575) 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: ( 820) minutes.
Conveyance self-test routine
recommended polling time: ( 2) minutes.
SCT capabilities: (0x70bd) 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_Error_Rate 0x000f 082 064 044 Pre-fail Always - 172055532
3 Spin_Up_Time 0x0003 089 089 000 Pre-fail Always - 0
4 Start/Stop_Count 0x0032 100 100 020 Old_age Always - 35
5 Retired_Sectors_Count 0x0033 100 100 010 Pre-fail Always - 0
7 Seek_Error_Rate 0x000f 094 060 045 Pre-fail Always - 2595397988
9 Power_On_Hours 0x0032 092 092 000 Old_age Always - 7008
10 Spin_Retry_Count 0x0013 100 100 097 Pre-fail Always - 0
12 Drive_Power_Cycle_Count 0x0032 100 100 020 Old_age Always - 35
184 Reported_IOEDC_errors 0x0032 100 100 099 Old_age Always - 0
187 Reported_Uncorrectables 0x0032 100 100 000 Old_age Always - 0
188 Command_Timeout_Count 0x0032 100 100 000 Old_age Always - 0
189 High_Fly_Writes 0x003a 100 100 000 Old_age Always - 0
190 Airflow_Temperature 0x0022 055 054 040 Old_age Always - 45 (Min/Max 44/46)
191 Shock_Count 0x0032 096 096 000 Old_age Always - 9115
192 Emergency_Retract_Counnt 0x0032 100 100 000 Old_age Always - 155
193 Load/Unload_Count 0x0032 100 100 000 Old_age Always - 299
194 Temperature 0x0022 045 046 000 Old_age Always - 45 (0 22 0 0 0)
195 ECC_On_the_Fly_Count 0x001a 082 064 000 Old_age Always - 172055532
197 Pending-Sparing_Count 0x0012 100 100 000 Old_age Always - 0
198 Uncorrectable_Sectors_Count 0x0010 100 100 000 Old_age Offline - 0
199 Ultra_DMA_CRC_Error_Count 0x003e 200 200 000 Old_age Always - 0
240 Head_Flight_Hours 0x0000 100 253 000 Old_age Offline - 190331475729217
241 Lifetime_Writes_From_Host 0x0000 100 253 000 Old_age Offline - 81260064418
242 Lifetime_Reads_From_host 0x0000 100 253 000 Old_age Offline - 130067558838
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 Interrupted (host reset) 00% 6522 -
# 2 Extended offline Interrupted (host reset) 00% 5145 -
# 3 Extended offline Completed without error 00% 4436 -
# 4 Extended offline Completed without error 00% 3720 -
# 5 Extended offline Completed without error 00% 3002 -
# 6 Extended offline Completed without error 00% 2281 -
# 7 Extended offline Completed without error 00% 1537 -
# 8 Extended offline Completed without error 00% 793 -
# 9 Extended offline Completed without error 00% 120 -
#10 Short offline Completed without error 00% 100 -
#11 Extended offline Completed without error 00% 90 -
#12 Extended offline Aborted by host 90% 0 -
#13 Short offline Completed without error 00% 0 -
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.