LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
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 04-07-2003, 12:13 PM   #1
Paul_assheton
Member
 
Registered: Nov 2000
Location: Ware (Nr London, England
Posts: 114

Rep: Reputation: 15
Problems with USB Flash device


Hi there,

I have a USB flash adapter that allows me to connect Compact Flash cards to my computer. It works automaticly under Win2k but I cannot get it to work under Linux. I have read various HOWTO's and threads on this site. Most of them are concerned with mounting the device. My problem is that the device appears to be configured but it is not connected to any device in /dev. I have tried various sd sg and hd devices in /dev.

Does anyone have any idea what the problem is.

Following is the output from /var/log/messages and lsmod

Thanks

Paul


Apr 7 18:14:40 paul2 kernel: hub.c: USB new device connect on bus2/1, assigned device number 2
Apr 7 18:14:41 paul2 kernel: usb.c: USB device 2 (vend/prod 0x7c4/0xa400) is not claimed by any active driver.
Apr 7 18:14:44 paul2 /etc/hotplug/usb.agent: Setup usb-storage for USB product 7c4/a400/113
Apr 7 18:14:44 paul2 kernel: Initializing USB Mass Storage driver...
Apr 7 18:14:44 paul2 kernel: usb.c: registered new driver usb-storage
Apr 7 18:14:44 paul2 kernel: usb-uhci.c: interrupt, status 2, frame# 1424
Apr 7 18:14:44 paul2 kernel: scsi2 : SCSI emulation for USB Mass Storage devices
Apr 7 18:14:44 paul2 kernel: USB Mass Storage support registered.




Module Size Used by Not tainted
usb-storage 62000 0
sr_mod 18136 0 (autoclean)
cmpci 35944 0 (autoclean)
soundcore 6500 4 (autoclean) [cmpci]
parport_pc 19108 1 (autoclean)
lp 8996 0 (autoclean)
parport 37152 1 (autoclean) [parport_pc lp]
autofs 13348 0 (autoclean) (unused)
tulip 43552 1
iptable_filter 2412 0 (autoclean) (unused)
ip_tables 14840 1 [iptable_filter]
ide-scsi 10512 0
ide-cd 33608 0
cdrom 33696 0 [sr_mod ide-cd]
nls_iso8859-1 3516 3 (autoclean)
nls_cp437 5116 3 (autoclean)
vfat 13084 3 (autoclean)
fat 38744 0 (autoclean) [vfat]
mousedev 5524 1
keybdev 2976 0 (unused)
hid 22244 0 (unused)
input 5888 0 [mousedev keybdev hid]
usb-uhci 26188 0 (unused)
usbcore 77056 1 [usb-storage hid usb-uhci]
ext3 70400 1
jbd 52212 1 [ext3]
advansys 93568 0 (unused)
sd_mod 13552 0 (unused)
scsi_mod 107144 5 [usb-storage sr_mod ide-scsi advansys sd_mod]
 
Old 04-07-2003, 07:41 PM   #2
finegan
LQ Guru
 
Registered: Aug 2001
Location: Dublin, Ireland
Distribution: Slackware
Posts: 5,700

Rep: Reputation: 72
The USB mass storage module is a little funky, check "dmesg" and see if you have anything that looks like:

Code:
Initializing USB Mass Storage driver...
usb.c: registered new driver usb-storage
scsi2 : SCSI emulation for USB Mass Storage devices
  Vendor: SIIG      Model: CompactFlash Car  Rev: 0113
  Type:   Direct-Access                      ANSI SCSI revision: 02
Attached scsi removable disk sda at scsi2, channel 0, id 0, lun 0
SCSI device sda: 15873 512-byte hdwr sectors (8 MB)
sda: test WP failed, assume Write Enabled
 sda: sda1
WARNING: USB Mass Storage data integrity not assured
The actual channel info doesn't get logged to /var/log/messages sometimes depending (plus the distros monkey with it, so I've gotten partial to dmesg, its purer.)

Cheers,

Finegan
 
Old 04-08-2003, 04:44 PM   #3
Paul_assheton
Member
 
Registered: Nov 2000
Location: Ware (Nr London, England
Posts: 114

Original Poster
Rep: Reputation: 15
Ok I looked at dmesg. The output looks like this

hub.c: USB new device connect on bus1/1/3, assigned device number 3
usb.c: USB device 3 (vend/prod 0x7c4/0xa400) is not claimed by any active driver.
Initializing USB Mass Storage driver...
usb.c: registered new driver usb-storage
usb-uhci.c: interrupt, status 2, frame# 368
scsi2 : SCSI emulation for USB Mass Storage devices
WARNING: USB Mass Storage data integrity not assured
USB Mass Storage device found at 3
USB Mass Storage support registered.
usbdevfs: USBDEVFS_CONTROL failed dev 3 rqt 128 rq 6 len 18 ret -84
usbdevfs: USBDEVFS_CONTROL failed dev 3 rqt 128 rq 6 len 18 ret -84


Any idea what the problem is. The error does not mean anything to me. Informantion I forgot to put in my first post is that the USB device is a Jenoptik Jenreader. The system is RH8.0.

Thanks

Paul
 
Old 04-08-2003, 06:52 PM   #4
rmartine
Member
 
Registered: Dec 2002
Location: San Luis Obispo, CA
Distribution: Fedora Core 3
Posts: 618

Rep: Reputation: 30
Mine was attached to sda1. It was a Lexmark Jump Drive.
 
Old 04-08-2003, 10:56 PM   #5
sinokonka
LQ Newbie
 
Registered: Apr 2003
Posts: 12

Rep: Reputation: 0
I've encountered the same.
And I find to resolve it very easy.
Just like this:

first,
cat /proc/partitions

get the detailed information on every mounted partitions

then,
cd /lib/modules/2.4.x-x/kernel/drivers
insmod ./scsi/scsi/scsi_mod.o
insmod ./scsi/sd_mod.o
insmod ./scsi/ide_scsi.o
insmod ./usb/usbcore.o
insmod ./usb/usb_uhci.o
insmod ./usb/usb_ohci.o

and see the partitions information again,

cat /proc/partitions
mount -t vfat /dev/sdax /mnt/usb_flash_memory

Hmmm...

It works.

Hope this help.
 
Old 04-08-2003, 10:57 PM   #6
sinokonka
LQ Newbie
 
Registered: Apr 2003
Posts: 12

Rep: Reputation: 0
Oh, but for every different version of distributions on linux, you may should change you file path.

good luck!

 
Old 04-09-2003, 01:31 AM   #7
carlywarly
Member
 
Registered: Feb 2003
Location: Sunny Southport, again.
Distribution: PCLinuxOS 0.93 and 0.92, Vector sometimes
Posts: 825

Rep: Reputation: 30
cdrecord -scanbus as root should tell you where your drive is on the scsi bus. Then you can make a symbolic link to mount it.
 
Old 04-09-2003, 11:36 AM   #8
Paul_assheton
Member
 
Registered: Nov 2000
Location: Ware (Nr London, England
Posts: 114

Original Poster
Rep: Reputation: 15
I have tried the suggestions above but still no mountable device. The error "usbdevfs: USBDEVFS_CONTROL failed dev 3 rqt 128 rq 6 len 18 ret -84" suggests that the device is just not configuring properly. The card reader device is probably not compatable with Linux.

Thanks for the help

Paul
 
Old 04-09-2003, 04:44 PM   #9
finegan
LQ Guru
 
Registered: Aug 2001
Location: Dublin, Ireland
Distribution: Slackware
Posts: 5,700

Rep: Reputation: 72
The device probably was not compatible with linux, what kernel and distro are you running, and if its 2.4.18 and RH8.0, that's a year and a half old kernel when a TON of usb support for mass-storage devices was added in both 2.4.19 and 2.4.20, I know, the PNY CF adapter I bought didn't work with 2.4.18, but worked with 2.4.19 which came out on the same day I bought the drive.

Cheers,

Finegan
 
Old 04-09-2003, 06:36 PM   #10
SenorPedo
Member
 
Registered: Oct 2002
Location: Richmond, VA
Distribution: RH7.3 & RH9
Posts: 40

Rep: Reputation: 15
Just a thought...do you have to update your fstab to tell it where to mount? It would probably be a line that looks like this:

/dev/sd0 /mnt/usbdisk auto noauto,owner,kudzu 0 0

and you'd have to create the mount point /mnt/usbdisk
Anyway, this is what I had to do get my USB storage stick to work. Good luck!

SenorPedo
 
Old 04-09-2003, 06:47 PM   #11
SenorPedo
Member
 
Registered: Oct 2002
Location: Richmond, VA
Distribution: RH7.3 & RH9
Posts: 40

Rep: Reputation: 15
Update to previous

Sorry, that should be /dev/sda0 or possibly /dev/sda1 not sd0. Hope this helps!
 
Old 04-10-2003, 03:51 AM   #12
Paul_assheton
Member
 
Registered: Nov 2000
Location: Ware (Nr London, England
Posts: 114

Original Poster
Rep: Reputation: 15
The idea about the Kernel is a good one thanks. I am waiting until I can download RH9 then I will try it again.

Thanks for the suggestion
 
Old 04-16-2003, 04:50 PM   #13
fantanas
LQ Newbie
 
Registered: Aug 2002
Location: New England (USA)
Posts: 10

Rep: Reputation: 0
Are you sure you have compiled the appropriate support? When you configure your kernel, under the general category "USB Support" you should find modules for different flash card readers.

In my case, I have been using a Microtech CF card reader with no problems. I remember that when I started using it, I had a kernel earlier than 2.4.18 (I think it was 2.4.17 because 2.4.16 had some broken USB drivers). This card reader worked fine with 2.4.18, 2.4.19 and now 2.4.20. My deistributions have been SuSE (now I have SuSE 8.1, but I upgraded its kernel to 2.4.20). Yes, what was said above, that every time you change kernel or distribution the CF shows up as different partition, seems to be true. I consider this a small price to pay. (Under Windows, what happens if a new device takes up an available drive letter and then software "breaks" because it expected a different drive?)

The CF cards show up as VFAT partitions. My digital camera is a Nikon Coolpix 990, which seems to have major problems with its USB because it does not run very well even under Windows. A few times I think the camera screwed up the file structure or partition of a card. I had to re-attach it to the camera and review some pics and then remount it under Linux. Reviewing those pics probably forced the camera to put the card file structure back in order.
 
Old 04-17-2003, 06:02 PM   #14
BaerRS
Member
 
Registered: Oct 2001
Location: Columbus, Ohio
Distribution: all.. but mainly SuSe--- looks like it changing to Red Hat
Posts: 119

Rep: Reputation: 15
I have a scandisk 6n1 reader (reads 6 different media types).. and I can mount a compact flash (havent tried the rest) fine with no problems.

the device (in redhat 8/9) is under /dev/usb/...
I'm not at my RH box right now.. and wont be back to it till Monday...
when I inserted the 6n1 reader, RH8/9 both made folders in /mnt/flash , all I had to do is issue a mount command from the /dev/usb/... to /mnt/flash and it worked. I didn't have to mess with the kernal.. (though I was useing the lated kernal from redhat via their RHN update)
 
  


Reply



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
Setting special permissions for USB flash device Shawn Parr SUSE / openSUSE 0 02-19-2005 06:04 PM
Two USB flash drives keep swapping device files pwalden Linux - General 8 12-30-2004 03:48 PM
USB flash unmount: device busy mkivihar Linux - Hardware 4 11-20-2004 10:32 AM
USB 2.0 Flash Drive Detected As Security Device? mtnbikerjerry Linux - Hardware 1 04-22-2004 10:54 AM
Automatically mounting a keyring usb flash device... Frustin Linux - Hardware 1 10-24-2003 10:45 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 08:54 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration