# USB hardware flashdrive recovery tools

## crumbs516

Hopefully I'm posting this in the right place as it is a hardware issue. I'm wondering if anyone has had any luck finding or writing tools to recovery USB flash drives with hardware faults. Specifically the device will suddenly no longer enumerate and reports failure to assign an address errors.

My USB drive reports errors similar to those seen when the USB host fails:

https://forums.gentoo.org/viewtopic-t-720908-highlight-usb+fails+enumerate.html

I know the system USB reading is fine and my problem is limited to a single flash drive. I believe the problem was caused when power was interrupted on another machine while the drive was mounted. All my searches for data|drive recovery return windows software that assumes the USB drive works but the user overwrote data or corrupted the filesystem. Any idea for how to get to the point that the device reports an address in /dev/ or to query/read the device without completely be recognized and placed in /dev?

Is there a hard power hardware reset for flash drives by applying a specific power sequence to the terminals? A user on http://www.linux-usb.org/notAcceptFeedback.html was able to recover a Palm device by power cycling.

Any help appreciated.

----------

## NeddySeagoon

crumbs516,

If the device will not enumerate, its either a power problem or the device is dead.

Try is as the only device on a set of root hubs, so it has the full 500mA available.

Some things don't like to share.

Post your /proc/bus/usb/devices file with the device connected.

----------

## crumbs516

dmesg output for the USB insert reduced to relevant material to reduce length. I didn't log on last night so I missed the proc request. I'll try to add the info later today.

```

```

...

[  212.042955] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 30

[  212.043081] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 31

[  212.043205] ehci_hcd 0000:00:02.2: devpath 7 ep0in 3strikes

[  212.094237] ehci_hcd 0000:00:02.2: port 7 high speed

[  212.094241] ehci_hcd 0000:00:02.2: GetStatus port 7 status 001005 POWER sig=se0 PE CONNECT

[  212.145007] usb 1-7: device descriptor read/64, error -71

[  212.297223] ehci_hcd 0000:00:02.2: port 7 high speed

[  212.297228] ehci_hcd 0000:00:02.2: GetStatus port 7 status 001005 POWER sig=se0 PE CONNECT

[  212.348008] usb 1-7: new high speed USB device using ehci_hcd and address 14

[  212.348056] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 1

[  212.348181] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 2

...

[  212.555914] ehci_hcd 0000:00:02.2: devpath 7 ep0out 3strikes

[  212.756004] usb 1-7: device not accepting address 14, error -71

[  212.807218] ehci_hcd 0000:00:02.2: port 7 high speed

[  212.807222] ehci_hcd 0000:00:02.2: GetStatus port 7 status 001005 POWER sig=se0 PE CONNECT

[  212.858008] usb 1-7: new high speed USB device using ehci_hcd and address 15

[  212.858140] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 1

[  212.858264] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 2

...

[  212.862014] ehci_hcd 0000:00:02.2: devpath 7 ep0out 3strikes

...

[  213.066873] ehci_hcd 0000:00:02.2: detected XactErr len 0/8 retry 31

[  213.066997] ehci_hcd 0000:00:02.2: devpath 7 ep0out 3strikes

[  213.268005] usb 1-7: device not accepting address 15, error -71

[  213.268012] hub 1-0:1.0: unable to enumerate USB device on port 7

[  213.274009] hub 1-0:1.0: state 7 ports 8 chg 0000 evt fe80

[  213.274016] ehci_hcd 0000:00:02.2: GetStatus port 7 status 003802 POWER OWNER sig=j CSC

[  213.274021] hub 1-0:1.0: port 7, status 0100, change 0001, 12 Mb/s

[  213.378009] hub 1-0:1.0: debounce: port 7: total 100ms stable 100ms status 0x100

[  213.378017] hub 2-0:1.0: state 7 ports 4 chg 0000 evt 0010

[  213.378026] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00010101 CSC PPS CCS

[  213.378031] hub 2-0:1.0: port 4, status 0101, change 0001, 12 Mb/s

[  213.482006] hub 2-0:1.0: debounce: port 4: total 100ms stable 100ms status 0x101

[  213.588007] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  213.639008] usb 2-4: new full speed USB device using ohci_hcd and address 3

[  213.641015] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  213.644013] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  213.647012] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  213.753008] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  213.804008] usb 2-4: device descriptor read/64, error -62

[  213.906994] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  213.909993] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  213.912992] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.019007] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  214.070007] usb 2-4: device descriptor read/64, error -62

[  214.277007] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  214.328008] usb 2-4: new full speed USB device using ohci_hcd and address 4

[  214.329961] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.332960] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.335960] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.442007] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  214.493006] usb 2-4: device descriptor read/64, error -62

[  214.595946] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.598941] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.601943] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0in 5ec20000 cc 5 --> status -62

[  214.708010] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  214.759022] usb 2-4: device descriptor read/64, error -62

[  214.966015] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  215.017008] usb 2-4: new full speed USB device using ohci_hcd and address 5

[  215.018912] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0out 5ec20000 cc 5 --> status -62

[  215.220895] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0out 5ec20000 cc 5 --> status -62

[  215.421007] usb 2-4: device not accepting address 5, error -62

[  215.527008] ohci_hcd 0000:00:02.0: GetStatus roothub.portstatus [3] = 0x00100103 PRSC PPS PES CCS

[  215.578009] usb 2-4: new full speed USB device using ohci_hcd and address 6

[  215.579868] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0out 5ec20000 cc 5 --> status -62

[  215.704017] hub 1-0:1.0: hub_suspend

[  215.704024] usb usb1: bus auto-suspend

[  215.704027] ehci_hcd 0000:00:02.2: suspend root hub

[  215.781860] ohci_hcd 0000:00:02.0: urb ffff8800b9cb9840 path 4 ep0out 5ec20000 cc 5 --> status -62

[  215.982011] usb 2-4: device not accepting address 6, error -62

[  215.982025] hub 2-0:1.0: unable to enumerate USB device on port 4

[  215.982030] hub 2-0:1.0: state 7 ports 4 chg 0000 evt 0010

[/code]

----------

## crumbs516

I'm guessing that not having /proc/bus/usb/devices change when the disk is inserted means it is toast. Am I wrong? I posted the  /proc/bus/usb/devices file content below with the disk inserted.

```

## /proc/bus/usb/devices

T:  Bus=03 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=12  MxCh= 4

B:  Alloc=  0/900 us ( 0%), #Int=  0, #Iso=  0

D:  Ver= 1.10 Cls=09(hub  ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1

P:  Vendor=1d6b ProdID=0001 Rev= 2.06

S:  Manufacturer=Linux 2.6.30-gentoo-r5 ohci_hcd

S:  Product=OHCI Host Controller

S:  SerialNumber=0000:00:02.1

C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub

E:  Ad=81(I) Atr=03(Int.) MxPS=   2 Ivl=255ms

T:  Bus=02 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=12  MxCh= 4

B:  Alloc= 28/900 us ( 3%), #Int=  2, #Iso=  0

D:  Ver= 1.10 Cls=09(hub  ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1

P:  Vendor=1d6b ProdID=0001 Rev= 2.06

S:  Manufacturer=Linux 2.6.30-gentoo-r5 ohci_hcd

S:  Product=OHCI Host Controller

S:  SerialNumber=0000:00:02.0

C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub

E:  Ad=81(I) Atr=03(Int.) MxPS=   2 Ivl=255ms

T:  Bus=02 Lev=01 Prnt=01 Port=01 Cnt=01 Dev#=  2 Spd=1.5 MxCh= 0

D:  Ver= 2.00 Cls=00(>ifc ) Sub=00 Prot=00 MxPS= 8 #Cfgs=  1

P:  Vendor=045e ProdID=00dd Rev= 1.73

S:  Manufacturer=Microsoft

S:  Product=Comfort Curve Keyboard 2000

C:* #Ifs= 2 Cfg#= 1 Atr=a0 MxPwr=100mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=03(HID  ) Sub=01 Prot=01 Driver=usbhid

E:  Ad=81(I) Atr=03(Int.) MxPS=   8 Ivl=10ms

I:* If#= 1 Alt= 0 #EPs= 1 Cls=03(HID  ) Sub=00 Prot=00 Driver=usbhid

E:  Ad=82(I) Atr=03(Int.) MxPS=   8 Ivl=10ms

T:  Bus=01 Lev=00 Prnt=00 Port=00 Cnt=00 Dev#=  1 Spd=480 MxCh= 8

B:  Alloc=  0/800 us ( 0%), #Int=  0, #Iso=  0

D:  Ver= 2.00 Cls=09(hub  ) Sub=00 Prot=00 MxPS=64 #Cfgs=  1

P:  Vendor=1d6b ProdID=0002 Rev= 2.06

S:  Manufacturer=Linux 2.6.30-gentoo-r5 ehci_hcd

S:  Product=EHCI Host Controller

S:  SerialNumber=0000:00:02.2

C:* #Ifs= 1 Cfg#= 1 Atr=e0 MxPwr=  0mA

I:* If#= 0 Alt= 0 #EPs= 1 Cls=09(hub  ) Sub=00 Prot=00 Driver=hub

E:  Ad=81(I) Atr=03(Int.) MxPS=   4 Ivl=256ms

```

----------

## NeddySeagoon

crumbs516,

Provided the FLASH stick was not connected to the same root hub as your keyboard, yep its toast.

Even toasted devices have ben know to appear in /proc/bus/usb/devices but if its not there, the kernel can't see it as a USB device at all.

----------

