LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (http://www.linuxquestions.org/questions/slackware-14/)
-   -   using a USB to ATA adaptor to read a disk in slackware gives kernel panic msgs (http://www.linuxquestions.org/questions/slackware-14/using-a-usb-to-ata-adaptor-to-read-a-disk-in-slackware-gives-kernel-panic-msgs-4175419394/)

nass 07-30-2012 01:21 PM

using a USB to ATA adaptor to read a disk in slackware gives kernel panic msgs
 
Hello everyone,
I had tried to tackle this problem in the past, but figured the disk might be broken in the end and let the thing there.

http://www.linuxquestions.org/questi...operly-945904/

Now, having installed a debian 6 in a pc that was laying around, I simply reconnected this disk to the adaptor and connected that adaptor to this pc and voila, I got the disk to be identified properly and saw my data on that disk!

So I basically want to get to the bottom of this and find out what I may have set up wrongly in my slackware64 (13.37) and can't get to read this disk.

ok some info . debian 6 is running on some 2.6.32.x kernel. slack is on a modified generic kernel (2.6.37.6 nevertheless). By modified I mean I had added some features, haven't really removed any.

now dmesg on the slackware system is interesting:

Quote:

usb 1-1: new high speed USB device using ehci_hcd and address 8
usb 1-1: New USB device found, idVendor=152d, idProduct=2338
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=5
usb 1-1: Product: USB to ATA/ATAPI bridge
usb 1-1: Manufacturer: JMicron
usb 1-1: SerialNumber: 43527242080A
usb 1-1: selecting invalid altsetting 1
scsi19 : usb-storage 1-1:1.0
scsi 19:0:0:0: Direct-Access FUJITSU MHT2080AT PQ: 0 ANSI: 2 CCS
sd 19:0:0:0: Attached scsi generic sg14 type 0
sd 19:0:0:0: [sdm] 156301488 512-byte logical blocks: (80.0 GB/74.5 GiB)
sd 19:0:0:0: [sdm] Write Protect is off
sd 19:0:0:0: [sdm] Mode Sense: 28 00 00 00
sd 19:0:0:0: [sdm] Assuming drive cache: write through
sd 19:0:0:0: [sdm] Assuming drive cache: write through
INFO: task kworker/u:2:15764 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
kworker/u:2 D ffff88021fcb4e48 0 15764 2 0x00000000
ffff8801956298e0 0000000000000046 ffff880195629880 ffffffff814e4a86
0000000000000000 00000000000118c0 00000000000118c0 ffff88021fcb4bc0
00000000000118c0 ffff880195629fd8 ffff880195628000 00000000000118c0
Call Trace:
[<ffffffff814e4a86>] ? scsi_request_fn+0xb6/0x410
[<ffffffff810cfdf0>] ? sync_page+0x0/0x50
[<ffffffff816a5870>] io_schedule+0x70/0xc0
per+0x0/0x10
INFO: task kworker/u:2:15764 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
kworker/u:2 D ffff88021fcb4e48 0 15764 2 0x00000000
ffff8801956298e0 0000000000000046 ffff880195629880 ffffffff814e4a86
0000000000000000 00000000000118c0 00000000000118c0 ffff88021fcb4bc0
00000000000118c0 ffff880195629fd8 ffff880195628000 00000000000118c0
Call Trace:
[<ffffffff814e4a86>] ? scsi_request_fn+0xb6/0x410
[<ffffffff810cfdf0>] ? sync_page+0x0/0x50
[<ffffffff816a5870>] io_schedule+0x70/0xc0

........... ALOT MORE KWORKER CRASHES OMITTED..................
INFO: task kworker/u:2:15764 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
kworker/u:2 D ffff88021fcb4e48 0 15764 2 0x00000000
ffff8801956298e0 0000000000000046 ffff880195629880 ffffffff814e4a86
0000000000000000 00000000000118c0 00000000000118c0 ffff88021fcb4bc0
00000000000118c0 ffff880195629fd8 ffff880195628000 00000000000118c0
Call Trace:
[<ffffffff814e4a86>] ? scsi_request_fn+0xb6/0x410
[<ffffffff810cfdf0>] ? sync_page+0x0/0x50

[<ffffffff810691b0>] ? worker_thread+0x0/0x340
[<ffffffff8106dc46>] kthread+0x96/0xa0
[<ffffffff81003794>] kernel_thread_helper+0x4/0x10
[<ffffffff8106dbb0>] ? kthread+0x0/0xa0
[<ffffffff81003790>] ? kernel_thread_helper+0x0/0x10
usb 1-1: USB disconnect, address 8
sd 19:0:0:0: timing out command, waited 180s
sd 19:0:0:0: [sdm] Unhandled error code
sd 19:0:0:0: [sdm] Result: hostbyte=0x07 driverbyte=0x00
sd 19:0:0:0: [sdm] CDB: cdb[0]=0x28: 28 00 00 00 00 00 00 00 08 00
end_request: I/O error, dev sdm, sector 0
Buffer I/O error on device sdm, logical block 0
Dev sdm: unable to read RDB block 0
sdm: unable to read partition table
sd 19:0:0:0: [sdm] READ CAPACITY failed
sd 19:0:0:0: [sdm] Result: hostbyte=0x01 driverbyte=0x00
sd 19:0:0:0: [sdm] Sense not available.
sd 19:0:0:0: [sdm] Assuming drive cache: write through
sd 19:0:0:0: [sdm] Attached SCSI disk
usb 1-1: new high speed USB device using ehci_hcd and address 9
usb 1-1: New USB device found, idVendor=152d, idProduct=2338
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=5
usb 1-1: Product: USB to ATA/ATAPI bridge
usb 1-1: Manufacturer: JMicron
usb 1-1: SerialNumber: 43527242080A
usb 1-1: selecting invalid altsetting 1
scsi20 : usb-storage 1-1:1.0
scsi 20:0:0:0: Direct-Access FUJITSU MHT2080AT PQ: 0 ANSI: 2 CCS
sd 20:0:0:0: Attached scsi generic sg14 type 0
sd 20:0:0:0: [sdm] 156301488 512-byte logical blocks: (80.0 GB/74.5 GiB)
sd 20:0:0:0: [sdm] Write Protect is off
sd 20:0:0:0: [sdm] Mode Sense: 28 00 00 00
sd 20:0:0:0: [sdm] Assuming drive cache: write through
sd 20:0:0:0: [sdm] Assuming drive cache: write through
usb 1-1: reset high speed USB device using ehci_hcd and address 9
usb 1-1: reset high speed USB device using ehci_hcd and address 9
usb 1-1: reset high speed USB device using ehci_hcd and address 9
usb 1-1: reset high speed USB device using ehci_hcd and address 9
usb 1-1: reset high speed USB device using ehci_hcd and address 9
sd 20:0:0:0: Device offlined - not ready after error recovery
sd 20:0:0:0: [sdm] Unhandled error code
sd 20:0:0:0: [sdm] Result: hostbyte=0x05 driverbyte=0x00
sd 20:0:0:0: [sdm] CDB: cdb[0]=0x28: 28 00 00 00 00 00 00 00 08 00
end_request: I/O error, dev sdm, sector 0
Buffer I/O error on device sdm, logical block 0
sd 20:0:0:0: rejecting I/O to offline device
sd 20:0:0:0: rejecting I/O to offline device
sd 20:0:0:0: rejecting I/O to offline device
sd 20:0:0:0: rejecting I/O to offline device
sd 20:0:0:0: rejecting I/O to offline device
sd 20:0:0:0: rejecting I/O to offline device
Dev sdm: unable to read RDB block 0
sd 20:0:0:0: rejecting I/O to offline device
sd 20:0:0:0: rejecting I/O to offline device
sdm: unable to read partition table
sd 20:0:0:0: [sdm] Attached SCSI disk
in the debian box even though I don't have access write now is pretty much the same as with slackware up to a point:

Quote:

usb 1-1: new high speed USB device using ehci_hcd and address 8
usb 1-1: New USB device found, idVendor=152d, idProduct=2338
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=5
usb 1-1: Product: USB to ATA/ATAPI bridge
usb 1-1: Manufacturer: JMicron
usb 1-1: SerialNumber: 43527242080A
usb 1-1: selecting invalid altsetting 1
scsi19 : usb-storage 1-1:1.0
scsi 19:0:0:0: Direct-Access FUJITSU MHT2080AT PQ: 0 ANSI: 2 CCS
sd 19:0:0:0: Attached scsi generic sg14 type 0
sd 19:0:0:0: [sdm] 156301488 512-byte logical blocks: (80.0 GB/74.5 GiB)
sd 19:0:0:0: [sdm] Write Protect is off
sd 19:0:0:0: [sdm] Mode Sense: 28 00 00 00
sd 19:0:0:0: [sdm] Assuming drive cache: write through
sd 19:0:0:0: [sdm] Assuming drive cache: write through
Afterwards, the debian loads the XFS module and reads the disk properly. It mentions somethings about the FS (ACLs enables, log, etcetc). Automount will mount the volume and i'll see the data.

On the slackware i'll be hearing the disk spin up and down constantly and the above dmesg will show up. I have included the xfs module statically in the kernel (not as module).

I'm appending some udevadm from both systems after i have plugged the disk to the adaptor and the adaptor to the usb port, they look pretty identical. The devices are identified that is. But i don't know yet what is wrong and I can't see this disk.
Can you help?

Thank you in advance for your help!


the comand is
Quote:

udevadm info -a -p /sys/block/sd_ , (where _ is b or m)
debian:
http://pastebin.com/YL7pLJ0Q

and slackware:
http://pastebin.com/kzALL9yc

guanx 07-31-2012 11:15 AM

I see from your other post that the disk has enough power. But did you try a SMART self test, or even further a test with the badblocks command?

nass 07-31-2012 12:23 PM

i'll try and get back to you

nass 08-02-2012 05:55 PM

well , no go, smartctl can't identify the device with this command:


root@stargaze:/# smartctl -d usbjmicron /dev/sdm
smartctl 5.40 2010-10-16 r3189 [x86_64-slackware-linux-gnu] (local build)
Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net

Smartctl open device: /dev/sdm [USB JMicron] failed: No such device
root@stargaze:/#

guanx 08-03-2012 07:27 AM

Quote:

Originally Posted by nass (Post 4744484)
well , no go, smartctl can't identify the device with this command:


root@stargaze:/# smartctl -d usbjmicron /dev/sdm
smartctl 5.40 2010-10-16 r3189 [x86_64-slackware-linux-gnu] (local build)
Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net

Smartctl open device: /dev/sdm [USB JMicron] failed: No such device
root@stargaze:/#

Connect it directly without a USB adaptor. To lower the costs USB adaptors don't support SMART.

nass 08-03-2012 09:44 AM

I can't it's a laptop disk, i needed the usb adaptor for exacty that reason,

Apparently, the specific USB adaptor should give out some data, i think...
http://sourceforge.net/apps/trac/smartmontools/wiki/USB

guanx 08-03-2012 10:24 AM

Quote:

Originally Posted by nass (Post 4744998)
I can't it's a laptop disk, i needed the usb adaptor for exacty that reason,

Apparently, the specific USB adaptor should give out some data, i think...
http://sourceforge.net/apps/trac/smartmontools/wiki/USB

My mistake.

The error "/dev/sdm: ... No such device" means that the kernel driver failed somewhere. Smartctl can do nothing.

Laptop disks are electrically compatible with desktop controllers.
If you value the data on that (very probably) corrupted disk, just try it on your desktop with an inexpensive adaptor (PATA) or directly (SATA).

nass 08-03-2012 11:45 AM

but it is not corrupted after all, on a debian system the disk is identified properly.
the modules seem to identify the disk, yet only in the debian system (with an older kernel) the disk shows up, again and again.

In slackware it doesn't it's probably some kernel option I can't even start to think about. but which one?


All times are GMT -5. The time now is 11:46 PM.