Sop*_*rez 57 hard-disk smart smartctl
我正在使用SmartMonTools测试硬盘。
测试前的硬盘状态(几天前仅进行了一次简短的测试):
$ sudo smartctl -l selftest /dev/sda
smartctl 6.2 2013-07-26 r3841 [i686-linux-3.16.0-30-generic] (local build)
Copyright (C) 2002-13, 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% 5167 -
Run Code Online (Sandbox Code Playgroud)
所以我开始了漫长的测试:
$ sudo smartctl -t long /dev/sda
smartctl 6.2 2013-07-26 r3841 [i686-linux-3.16.0-30-generic] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF OFFLINE IMMEDIATE AND SELF-TEST SECTION ===
Sending command: "Execute SMART Extended self-test routine immediately in off-line mode".
Drive command "Execute SMART Extended self-test routine immediately in off-line mode" successful.
Testing has begun.
Please wait 130 minutes for test to complete.
Test will complete after Sat May 9 16:05:27 2015
Use smartctl -X to abort test.
Run Code Online (Sandbox Code Playgroud)
测试应该正在运行,但是如果我尝试查看它的进度:
$ sudo smartctl -l selftest /dev/sda
smartctl 6.2 2013-07-26 r3841 [i686-linux-3.16.0-30-generic] (local build)
Copyright (C) 2002-13, 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% 5167 -
Run Code Online (Sandbox Code Playgroud)
...我得到的只是相同的结果,就像现在没有运行/执行测试一样。
'-H' 参数没有提供更多信息:
$ sudo smartctl -H /dev/sda
smartctl 6.2 2013-07-26 r3841 [i686-linux-3.16.0-30-generic] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
Run Code Online (Sandbox Code Playgroud)
并且,只要没有进程在运行(这个测试是由硬盘控制器单独执行的),一些ps -e样式搜索也无济于事。
我怎么知道现在是否有一些 SMART 自检正在运行?
fro*_*utz 62
在smartctl -a <device>寻找Self-test execution status。
没有测试运行时的示例:
Self-test execution status: ( 0) The previous self-test routine completed
without error or no self-test has ever
been run.
Run Code Online (Sandbox Code Playgroud)
测试运行时的示例:
Self-test execution status: ( 249) Self-test routine in progress...
90% of test remaining.
Run Code Online (Sandbox Code Playgroud)
运行选择性自检 ( -t select) 时,此处还会显示进度:
SMART Selective self-test log data structure revision number 1
SPAN MIN_LBA MAX_LBA CURRENT_TEST_STATUS
1 0 125045423 Self_test_in_progress [90% left] (2881512-2947047)
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
50141 次 |
| 最近记录: |