LinuxQuestions.org
Visit the LQ Articles and Editorials section
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-12-2008, 06:44 AM   #1
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Rep: Reputation: Disabled
USB external disk freezes every 2-3 minutes with reset.


My USB external disks freezes periodically - dmesg shows
Quote:
usb 1-1: reset high speed USB device using ehci_hcd and address 2
I bought the external drives as an archive for films and music - clearly they are not much use for this if they keep on freezing every 2-3 minutes.

Any ideas?
 
Old 09-12-2008, 06:51 AM   #2
titopoquito
Senior Member
 
Registered: Jul 2004
Location: Ruhr Area, Germany
Distribution: Slackware64 14.0
Posts: 1,517

Rep: Reputation: 90
Is this a 2,5" (or smaller) or a 3,5" device? Switching the usb port to rear ones (on a desktop) might help if it is a power issue. Some 2,5" disks say they don't need an external power supply but actually run unstable or not at all without an usb-y-cable.

It might also be an issue with power saving options, like the Seagate FreeAgent disks suffer from. I guess a google search should show you if your harddisk advertizes such a feature. There are many threads about the FreeAgent devices at least.

So far two ideas, I hope it's kind of helpful for you.
 
Old 09-12-2008, 08:09 AM   #3
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Thanks titopoquito.

It's a 3.5" device with external power connected via USB2.0.

I too thought it may have something to do with powersaving options.

However, I 've just tried again - the film took ages to load, but then ran for about 20 minutes and then froze. Dmesg showed
Quote:
usb 1-1: reset high speed USB device using ehci_hcd and address 2
usb 1-1: device descriptor read/64, error -110
usb 1-1: reset high speed USB device using ehci_hcd and address 2
Here's some more info:

lsusb
Quote:
Bus 001 Device 002: ID 067b:0600 Prolific Technology, Inc.
lsscsi
Quote:
[2:0:0:0] disk SAMSUNG HD103UJ 1AA0 /dev/sda
lspci
Quote:
00:00.0 Host bridge: Intel Corporation 82845 845 [Brookdale] Chipset Host Bridge (rev 03)
00:01.0 PCI bridge: Intel Corporation 82845 845 [Brookdale] Chipset AGP Bridge (rev 03)
00:1e.0 PCI bridge: Intel Corporation 82801 PCI Bridge (rev 12)
00:1f.0 ISA bridge: Intel Corporation 82801BA ISA Bridge (LPC) (rev 12)
00:1f.1 IDE interface: Intel Corporation 82801BA IDE U100 Controller (rev 12)
00:1f.2 USB Controller: Intel Corporation 82801BA/BAM USB Controller #1 (rev 12)
00:1f.3 SMBus: Intel Corporation 82801BA/BAM SMBus Controller (rev 12)
00:1f.4 USB Controller: Intel Corporation 82801BA/BAM USB Controller #1 (rev 12)
00:1f.5 Multimedia audio controller: Intel Corporation 82801BA/BAM AC'97 Audio Controller (rev 12)
02:05.0 VGA compatible controller: Matrox Graphics, Inc. MGA 2064W [Millennium] (rev 01)
02:08.0 Ethernet controller: Intel Corporation 82801BA/BAM/CA/CAM Ethernet Controller (rev 03)
02:0f.0 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 62)
02:0f.1 USB Controller: VIA Technologies, Inc. VT82xxxxx UHCI USB 1.1 Controller (rev 62)
02:0f.2 USB Controller: VIA Technologies, Inc. USB 2.0 (rev 65)
hdparm -I /dev/sda

Quote:
/dev/sda:
SG_IO: bad/missing ATA_16 sense data:: 70 00 05 00 00 00 00 0a 00 00 00 00 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
SG_IO: bad/missing ATA_16 sense data:: 70 00 05 00 00 00 00 0a 00 00 00 00 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
HDIO_DRIVE_CMD(identify) failed: Input/output error
hdparm -i /dev/sda
Quote:
/dev/sda:
HDIO_GET_IDENTITY failed: Invalid argument
sdparm -a /dev/sda
Quote:
/dev/sda: SAMSUNG HD103UJ 1AA0
Btw, after freezing for about a minute or two, the drive then continues to work - until the next freeze.
 
Old 09-12-2008, 08:46 AM   #4
pwc101
Senior Member
 
Registered: Oct 2005
Location: UK
Distribution: Slackware
Posts: 1,847

Rep: Reputation: 128Reputation: 128
Just a thought: it's not a SeaGate FreeAgent drive is it? If so, see here: http://www.engadget.com/2007/12/07/s...wn-with-linux/
 
Old 09-12-2008, 09:35 AM   #5
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
I have a Samsung disk, pwc101. But that link was interesting in that it points out that at least one disk has problems with sleep mode and that its manufacturer is most definitely anti-linix!

Quote:
It seems as if FreeAgent owners that prefer a more open operating system have been experiencing issues with the drive for a little while now, but we're finally seeing that Seagate isn't exactly rushing to the rescue. Apparently, the power-saving settings on the drives in question only function as advertised in Windows, and users running Linux (and OS X, we presume) could see their FreeAgent duck into inactivity, only to have the USB connection drop and reconnect as USB 1.1. Furthermore, we've even seen an e-mail response from the firm tersely stating that it "does not provide support for Personal / External Storage products (and / or accessories) used in a Linux environment." So, dear readers, are any of you fighting this same battle, and if so, have you found a sufficient workaround?
Anyway, I think it safe to safe to say that the problem is NOT related to disks or enclosures since I have now mounted my second external disk to the next port and I am getting the same problems.

Thus I have two disks with two enclosures behaving similarly, the first disk a sata 1TB disk and the second a pata 500GB disk.

Quote:
#sdparm /dev/sda
/dev/sda: SAMSUNG HD103UJ 1AA0

#sdparm /dev/sdb
/dev/sdb: ST350063 0A 3.AA
 
Old 09-12-2008, 10:24 AM   #6
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Here are the messages sent to dmeg from connecting the second disk, mounting it and then playing a film on the that disk. It took a long time to load and then froze twice before I quit.

Quote:
usb 1-2: new high speed USB device using ehci_hcd and address 5
usb 1-2: configuration #1 chosen from 1 choice
scsi5 : SCSI emulation for USB Mass Storage devices
usb-storage: device found at 5
usb-storage: waiting for device to settle before scanning
scsi 5:0:0:0: Direct-Access ST350063 0A 3.AA PQ: 0 ANSI: 0
sd 5:0:0:0: [sdb] 976773168 512-byte hardware sectors (500108 MB)
sd 5:0:0:0: [sdb] Write Protect is off
sd 5:0:0:0: [sdb] Mode Sense: 03 00 00 00
sd 5:0:0:0: [sdb] Assuming drive cache: write through
sd 5:0:0:0: [sdb] 976773168 512-byte hardware sectors (500108 MB)
sd 5:0:0:0: [sdb] Write Protect is off
sd 5:0:0:0: [sdb] Mode Sense: 03 00 00 00
sd 5:0:0:0: [sdb] Assuming drive cache: write through
sdb: sdb1 sdb2 < sdb5 sdb6 sdb7 sdb8 >
sd 5:0:0:0: [sdb] Attached SCSI disk
sd 5:0:0:0: Attached scsi generic sg1 type 0
usb-storage: device scan complete
kjournald starting. Commit interval 5 seconds
EXT3 FS on sdb1, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on sdb5, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on sdb6, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on sdb7, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
kjournald starting. Commit interval 5 seconds
EXT3 FS on sdb8, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
usb 1-2: reset high speed USB device using ehci_hcd and address 5
usb 1-2: reset high speed USB device using ehci_hcd and address 5
usb 1-2: reset high speed USB device using ehci_hcd and address 5
usb 1-2: reset high speed USB device using ehci_hcd and address 5
 
Old 09-12-2008, 10:27 AM   #7
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Since this is not a Slackware question per se, I'll ask the moderators to move this thread to the hardware forum.
 
Old 09-12-2008, 11:37 AM   #8
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
I am copying a file from one partion to another on the external disk and it is doing a reset every minute. It is taking ages.

My /var/log/messages file is a mass of reset messages:

Quote:
kernel: usb 1-2: reset high speed USB device using ehci_hcd and address 5

Last edited by harryhaller; 09-12-2008 at 11:38 AM.
 
Old 09-12-2008, 12:32 PM   #9
keefaz
Senior Member
 
Registered: Mar 2004
Distribution: Slackware
Posts: 4,539

Rep: Reputation: 119Reputation: 119
A quick google search leads to a possible fix by reducing the max_sectors on device:
(eg for sdb)
echo 128 > /sys/block/sdb/device/max_sectors
Maybe even reduce this value to 64, 32 until it becomes stable
http://bugs.gentoo.org/show_bug.cgi?id=177266
 
Old 09-12-2008, 01:20 PM   #10
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by keefaz View Post
A quick google search leads to a possible fix by reducing the max_sectors on device:
<cough> I've been googling for a week !

I tried
Code:
echo 128 > /sys/block/sdb/device/max_sectors
but no effect nor did 64 or 32 sectors. It is still resetting at about once per minute.
 
Old 09-12-2008, 02:59 PM   #11
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Thanks for that link, keefaz.

Some of the reference links suggest it may be the USB_EHCI_HCD which is causing the problem.

I will recompile the kernel without USB_EHCI_HCD and see how that works.
 
Old 09-14-2008, 03:15 AM   #12
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Smile Solution

Please excuse my euphoria, but after fearing I had wasted a 100 and more on a USB external disk and a week of work, I have got the usb external disk working without error.

If you have the same problems, then recompile the kernel without CONFIG_USB_EHCI_HCD.

Do not try, as I did, to see if you can get away with dropping some of the sub-options of CONFIG_USB_EHCI_HCD, it won't change anything.

I have tested copying a file from the usb external to an internal disk and copying from one partition to another partition on the same external disk - both rock solid without a single reset message!

The question now remains:
USB_EHCI_HCD
What is it good for?
Absolutely nothing?


Well, I suppose that most people don't live in a dumpster with a pedal powered PC like I do.

No, but seriously, I only have usb 1.1 on my motherboard, so I have a usb 2.0 card added - does USB_EHCI_HCD have a problem with that?

Many thanks to Ralf, whose post at the bottom of this page gave me the solution and to keefaz, fellow LQer and Slacker, whose link led me to that link.
 
Old 10-04-2008, 01:41 AM   #13
sixerjman
Member
 
Registered: Sep 2004
Distribution: Debian Tesing / Unstable
Posts: 166
Blog Entries: 1

Rep: Reputation: 30
EHCI_HCD provides high speed transfers (aka USB 2.0), 480 mb/s. USB 1 or 1.1 with external hard drives is unacceptable, it takes forever. I"ve been using a Seagate external drive with a PCI-USB 2.0 card for months and just today the drive started disconnecting and it just sucks trying to do anything after the reset. Booting to GUI used to take 2 minutes now takes 10 minutes. This is a bad problem with the EHCI driver
and fallback to UHCI or OHCI is not an option for me. The problem seems to occur whenever any intensive I/O to the drive takes place (like when it is just coming online and the scan starts of a large partition - I've got about 100 gig of music and movies on it).
 
Old 10-14-2008, 07:07 AM   #14
harryhaller
Member
 
Registered: Sep 2004
Posts: 429

Original Poster
Rep: Reputation: Disabled
Well, it's a bit of comfort to know I'm not the only one with this problem.

At the moment I don't load the EHCI_HCD module and watching films etc. is ok. If I want to write a large file, such as a 1gb film to the external disk, I load the EHCI_HCD module - and then remove it again to watch the film.

I live with that "solution" and don't have the time at the moment to experiment with building different kernels and checking for differences.

Maybe, one day, someone will discover the bug... maybe.
 
  


Reply

Tags
externalharddrive, usb disk


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
usb external HD issue: reset high speed USB device using ehci_hcd gstath Slackware 4 08-18-2010 01:35 AM
60GB laptop hard disk & 200GB external USB hard disk linux compatibility powah Linux - Hardware 0 03-07-2006 10:55 AM
USB disk lost after 10 minutes pingu Mandriva 2 01-16-2006 03:14 AM
usb controller dies mounting external usb hard disk komasoftware Linux - Hardware 4 11-30-2005 01:18 PM
USB 2.0 External Disk Wont Work, but almost in USB 1.1 integr8er Linux - Hardware 2 03-13-2004 09:22 AM


All times are GMT -5. The time now is 07:28 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