我正在为摄影师朋友排除外部硬盘故障。她在外部硬盘上存储了一年的照片,但不幸的是,Windows(她常用的操作系统)无法识别或安装它。即使硬盘被毁了,恢复信息也是一件好事。
硬盘是 Seagate 生产的 BUP Slim SL 磁盘驱动器,带有 USB 连接器。我已将其插入运行 Ubuntu 的计算机上正常工作的 USB 驱动器(已使用另一台设备进行预先测试以确保无误)。我尝试了以下操作:
(1):尝试了 fdisk,绝不识别驱动器:
sudo fdisk -l
(2):我连续尝试了两次:
dmesg | tail -n 20
首先,驱动器被识别:
[user]$ dmesg | tail -n 20
[75790.056781] usb 2-1.5: new high-speed USB device number 8 using ehci-pci
[75790.223408] usb 2-1.5: New USB device found, idVendor=0bc2, idProduct=ab26
[75790.223415] usb 2-1.5: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[75790.223420] usb 2-1.5: Product: BUP Slim SL
[75790.223424] usb 2-1.5: Manufacturer: Seagate
[75790.223429] usb 2-1.5: SerialNumber: NA9DCBRL
[75790.225879] scsi host11: uas
[75790.226838] scsi 11:0:0:0: Direct-Access Seagate BUP Slim SL 0108 PQ: 0 ANSI: 6
[75790.246556] sd 11:0:0:0: Attached scsi generic sg7 type 0
在磁盘旋转之前的这个短暂的时间窗口中,sg7 出现在 /dev 中:
[user]$ ls /dev | grep sg
bsg
kmsg
sg0
sg1
sg2
sg3
sg4
sg5
sg6
sg7
过了一会儿,我再次检查 dmesg,发现磁盘正在旋转,并显示以下输出:
[user]$ dmesg | tail -n 20
[75790.246556] sd 11:0:0:0: Attached scsi generic sg7 type 0
[75798.642812] sd 11:0:0:0: [sdf] Spinning up disk...
[75800.421000] usb 2-1.5: stat urb: status -71
[75800.632234] usb 2-1.5: USB disconnect, device number 8
[75800.632402] sd 11:0:0:0: tag#0 uas_zap_pending 0 uas-tag 1 inflight: CMD
[75800.632410] sd 11:0:0:0: tag#0 CDB: Test Unit Ready 00 00 00 00 00 00
[75800.366209] .ready
[75800.722111] sd 11:0:0:0: [sdf] Read Capacity(16) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[75800.722120] sd 11:0:0:0: [sdf] Sense not available.
[75800.812119] sd 11:0:0:0: [sdf] Read Capacity(10) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[75800.812127] sd 11:0:0:0: [sdf] Sense not available.
[75800.878119] sd 11:0:0:0: [sdf] Write Protect is off
[75800.878128] sd 11:0:0:0: [sdf] Mode Sense: 00 00 00 00
[75800.908167] sd 11:0:0:0: [sdf] Asking for cache data failed
[75800.908176] sd 11:0:0:0: [sdf] Assuming drive cache: write through
[75801.084129] sd 11:0:0:0: [sdf] Read Capacity(16) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[75801.084137] sd 11:0:0:0: [sdf] Sense not available.
[75801.174187] sd 11:0:0:0: [sdf] Read Capacity(10) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[75801.174194] sd 11:0:0:0: [sdf] Sense not available.
启动时似乎出现了一些错误,但是我无法从此输出中获取更多信息。我尝试在互联网上搜索“dmesg:status -71”,但没有找到。此外,此时,设备从 /dev 中消失:
[user]$ ls /dev | grep sg
bsg
kmsg
sg0
sg1
sg2
sg3
sg4
sg5
sg6
有人在安装外部磁盘驱动器时遇到过类似的问题,或者了解 dmesg 的输出吗?如前所述,我在线搜索了“dmesg 输出:状态 -71”,但没有任何结果。也许这不是 dmesg 错误代码?我一无所知。即使驱动器本身无法挽救,如果知道驱动器上的照片是否可以挽救,那就太好了。
任何帮助是极大的赞赏!
保罗。
笔记:我昨天在 Ubuntu 论坛上发布了同样的问题,但是没有得到任何回应。 https://ubuntuforums.org/showthread.php?t=2397579
更新 #1:我发现了这篇文章(https://forums.suse.com/archive/index.php/t-5133.html) 于 2014 年 (来自用户 clausbc) 发布了一条关于 Seagate USB 硬盘系列的信息。问题看起来完全相同,磁盘旋转后设备断开连接,内容如下:
[ 3618.458008] sd 3:0:0:0: [sda] Spinning up disk........................
[ 3644.096435] usb 1-6: USB disconnect, device number 2
[ 3645.020070] .ready
[ 3645.020154] sd 3:0:0:0: [sda] READ CAPACITY(16) failed
[ 3645.020157] sd 3:0:0:0: [sda] Result: hostbyte=DID_NO_CONNECT driverbyte=DRIVER_OK
[ 3645.020162] sd 3:0:0:0: [sda] Sense not available.
[ 3645.020194] sd 3:0:0:0: [sda] READ CAPACITY failed
这与我的 dmesg 输出几乎相同:
[75798.642812] sd 11:0:0:0: [sdf] Spinning up disk...
[75800.421000] usb 2-1.5: stat urb: status -71
[75800.632234] usb 2-1.5: USB disconnect, device number 8
[75800.632402] sd 11:0:0:0: tag#0 uas_zap_pending 0 uas-tag 1 inflight: CMD
[75800.632410] sd 11:0:0:0: tag#0 CDB: Test Unit Ready 00 00 00 00 00 00
[75800.366209] .ready
[75800.722111] sd 11:0:0:0: [sdf] Read Capacity(16) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[75800.722120] sd 11:0:0:0: [sdf] Sense not available.
[75800.812119] sd 11:0:0:0: [sdf] Read Capacity(10) failed: Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[75800.812127] sd 11:0:0:0: [sdf] Sense not available.
论坛用户 jmozdzen 说,“[ 3645.020157] sd 3:0:0:0: [sda] Result: hostbyte=DID_NO_CONNECT driverbyte=DRIVER_OK”这一行表明(从内核的角度来看)驱动程序未连接。
有没有办法让我保持外部驱动器的连接,以便它继续在 /dev 中显示为 sg7?或者这是在发生某些严重故障时保护硬盘的安全功能?目前,我研究此问题的唯一可用工具是 dmesg,并且仅在断开连接之前的这个短暂窗口中...
更新 #2:我通过 lsusb 发现了以下内容:
[user]$ lsusb -v
Bus 002 Device 013: ID 0bc2:ab26 Seagate RSS LLC Backup Plus Slim Portable Drive 1 TB
Couldn't open device, some information will be missing
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.10
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x0bc2 Seagate RSS LLC
idProduct 0xab26 Backup Plus Slim Portable Drive 1 TB
bcdDevice 1.08
iManufacturer 1
iProduct 2
iSerial 3
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 85
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 500mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 80 Bulk-Only
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x81 EP 1 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x02 EP 2 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 1
bNumEndpoints 4
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 98
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Command pipe (0x01)
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Status pipe (0x02)
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Data-in pipe (0x03)
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x04 EP 4 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Data-out pipe (0x04)
我读到过一些文章说模块 uas 和这些 Seagate usb 驱动器之间可能会发生冲突。我使用“sudo modprobe -r uas”关闭了模块,但这是不是有帮助的。
答案1
有一定几率,只有驱动器的 USB 控制器部分有缺陷。
因此,您的机会是从 USB 盒中取出驱动器,并将其直接连接到计算机的 SATA 端口(如果这是旧驱动器,则通过适配器连接到 2.5 英寸 IDE 端口)。
然后,您可以直接访问驱动器,如果驱动器仍能正常工作,则从中复制所有数据。这样,您还可以S.M.A.R.T.
通过 获得更具信息量的数值读数smartctl
。
您可以S.M.A.R.T.
使用以下方式安装工具
sudo apt-get install smartmontools
并获取所有值(调整驱动器路径/dev/sda
)
sudo smartctl --all /dev/sda