我最近尝试获取 WD My Passport USB 硬盘的智能状态。我第一次运行$ smartctl -a /dev/disk3,但显然输出必然是:
smartctl 7.2 2020-12-30 r5155 [Darwin 18.7.0 x86_64] (local build)
Copyright (C) 2002-20, Bruce Allen, Christian Franke, www.smartmontools.org
Smartctl open device: /dev/disk3 failed: Operation not supported by device
Run Code Online (Sandbox Code Playgroud)
我检查了 smartmontools wiki 以查找有关USB 硬盘驱动器使用说明,并发现您必须添加-d正确的驱动程序,在我的例子中是-d sat. 不幸的是,macOS Mojave 上正确命令的输出是:
$ smartctl -d sat -a /dev/disk3
smartctl 7.2 2020-12-30 r5155 [Darwin 18.7.0 x86_64] (local build)
Copyright (C) 2002-20, Bruce Allen, Christian Franke, www.smartmontools.org
/dev/disk3: Type 'sat+...': …Run Code Online (Sandbox Code Playgroud)