LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 09-10-2006, 11:34 PM   #1
human_blip
LQ Newbie
 
Registered: Mar 2006
Posts: 4

Rep: Reputation: 0
usb hdd "device not ready" on write after short idle time


I have an external usb hdd that seems to be working fine under windows XP but is giving me grief under linux. The first thing I noticed is that a file system mounted on the drive would switch from read/write mode to read only mode after a seemingly unpredictable write error.

Looking at dmesg I found 'Device not ready' errors for the drive. After playing with it for a while I have discovered that sustained read or write activity to the drive will prevent the device not ready errors from occurring, but that the first write attempt after an idle period of a few seconds produces an error every time.

I get the same result under Fedora Core 4 and Kubuntu dapper.

Is this a hardware glitch or a driver problem? XP seems to cope with it OK.

The drive is a Samsung HM12JC - 2.5 inch 120 Gb ide - connected through an Alcor Micro Corp AU6390 USB2.0 to ATA/ATAPI Bridge Controller.

relevent lines from dmesg:
[17341301.700000] scsi11 : SCSI emulation for USB Mass Storage devices
[17341301.700000] usb-storage: device found at 14
[17341301.700000] usb-storage: waiting for device to settle before scanning
[17341306.700000] Vendor: Generic Model: USB Disk Rev: 9.02
[17341306.700000] Type: Direct-Access ANSI SCSI revision: 02
[17341306.700000] SCSI device sdb: 234441648 512-byte hdwr sectors (120034 MB)
[17341306.700000] sdb: assuming drive cache: write through
[17341306.704000] SCSI device sdb: 234441648 512-byte hdwr sectors (120034 MB)
[17341306.704000] sdb: assuming drive cache: write through
[17341306.704000] sdb: sdb1 sdb2 sdb3 sdb4 < sdb5 >
[17341306.828000] sd 11:0:0:0: Attached scsi disk sdb
[17341306.828000] sd 11:0:0:0: Attached scsi generic sg2 type 0
[17341306.828000] usb-storage: device scan complete
[17343249.960000] sd 11:0:0:0: Device not ready.
[17343249.960000] end_request: I/O error, dev sdb, sector 200000



lsusb -v -s 5:14

Bus 005 Device 014: ID 058f:6390 Alcor Micro Corp.
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x058f Alcor Micro Corp.
idProduct 0x6390
bcdDevice 1.00
iManufacturer 1 Generic
iProduct 2 USB TO IDE Bridge
iSerial 0
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 32
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xc0
Self Powered
MaxPower 100mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 80 Bulk (Zip)
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
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
Device Qualifier (for other device speed):
bLength 10
bDescriptorType 6
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
bNumConfigurations 1
Device Status: 0x0000
(Bus Powered)
 
Old 09-14-2006, 03:05 AM   #2
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,675

Rep: Reputation: Disabled
Quote:
Originally Posted by human_blip
...
[17343249.960000] sd 11:0:0:0: Device not ready.
[17343249.960000] end_request: I/O error, dev sdb, sector 200000
Does this happen at reboot too (I mean without the drive powering down)? If it is not ready -- it is not ready, after all. .

Checked the cable? Checked the file system (fschk)? What's at sector 200000?
 
Old 09-17-2006, 02:57 AM   #3
human_blip
LQ Newbie
 
Registered: Mar 2006
Posts: 4

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by JZL240I-U
Does this happen at reboot too (I mean without the drive powering down)? If it is not ready -- it is not ready, after all. .

Checked the cable? Checked the file system (fschk)? What's at sector 200000?
Have checked with several different cables and on several different computers. This is independent of the filesystem or any particular sector. Writing to any part of the disc (eg via dd or badblocks -w) after a few seconds of the disk being idle results in "Device not ready" messages. If the disk is kept busy (with other writes or reads) then there is no problem in writing. It is only the first write after idle that results in "Device not ready." The drive is powered via the USB. It does not power down - at least it does not spin down. I don't know how to check or control whether a usb hard drive enters into some power saving state while it is idle.
 
Old 09-18-2006, 03:16 AM   #4
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,675

Rep: Reputation: Disabled
What is the BIOS entry for the drive? I mean, could there lie any cause for this behaviour?
 
Old 09-20-2006, 06:08 PM   #5
human_blip
LQ Newbie
 
Registered: Mar 2006
Posts: 4

Original Poster
Rep: Reputation: 0
This is a USB hard disk drive - it doesn't have a bios entry.
 
Old 09-21-2006, 01:20 AM   #6
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,675

Rep: Reputation: Disabled
Oh, right, my error. I reasoned that there might be some power-down parameter set in the BIOS. I don't really have that much experience with USB (my board supports only 1.1, so it's no use for hard disks).

KDE (in Kubuntu) has at least two USB monitoring tools. Try those to find out whether there is any power-down-on-idle setting. Is the power drain of the disk within the specs of your USB ATA/ATAPI Bridge Controller?
 
Old 10-13-2006, 01:52 AM   #7
human_blip
LQ Newbie
 
Registered: Mar 2006
Posts: 4

Original Poster
Rep: Reputation: 0
Looks like there is a problem with the USB2.0 to ATA/ATAPI Bridge Controller I was using. I switched to a different one and have no more problem. Still not sure if it is a problem with the Alcor Micro Corp AU6390 in general or just the particular one I bought.
 
Old 10-13-2006, 02:31 AM   #8
JZL240I-U
Senior Member
 
Registered: Apr 2003
Location: Germany
Distribution: openSuSE 13.1 / 12.3_64-KDE, Ubuntu 14.04, Fedora 20, Mint 17, Chakra
Posts: 3,675

Rep: Reputation: Disabled
Aha. Thank you for reporting back .
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
kernel-2.6.11-1.14_FC3 disables usb keyboard after short idle time acebass Fedora 2 05-22-2005 09:02 AM
usb drive "protocol device" - why cannot I write to it? lefty.crupps Linux - Hardware 2 04-28-2005 09:32 PM
Gaim idle time reporting: "x usage" option disappeared DiscoStoo Linux - Software 2 12-23-2004 02:32 PM
External USB HDD"Mounting local filesystems: /dev/sdb1 is not a valid block device" manudath Linux - Hardware 3 12-13-2004 09:59 PM
"Unable to open USB device "usb://hp/LaserJet%201000": No such device" lordshipmayhem Mandriva 2 08-08-2004 04:56 PM


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

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration