Link to home
Start Free TrialLog in
Avatar of iharpsoln
iharpsoln

asked on

Mounting problem: USB storage device on RHEL 3.0...


Hi:

I have a Memorex 256MB USB thumbdrive that I occasionally plug into my RedHat Enterpise Linux 3.0 PC. As of yesterday, when I plug it in and try and mount it, I get an error and I can't figure it out.
I have never had this problem with it before.
The following is what I do:

$ mkdir -p /mnt/mrexdisk
$ mount -tvfat /dev/sda1 /mnt/mrexdisk

The mount command returns the following error:

mount: /dev/sda1 is not a valid block device

My storage device has been formatted in FAT.
I continue to plug it in and use it on my Windows PC all the time (reading/writing to it) without any problem.

Thanks in Advance for your help.


Avatar of Luxana
Luxana
Flag of Australia image

try:

 mount -t vfat /dev/sda1 /mnt/mrexdisk
or just
mount  /dev/sda1 /mnt/mrexdisk

also you can edit /etc/fstab to make it automatic
then you need just
mount /dev/sda1
Avatar of iharpsoln
iharpsoln

ASKER


Luxana:

Thanks for the reply, but I had already tried what you and it didn't solve the problem.
Is the device being recognised as a storage device at sda? Check with dmesg after you plug it in.
yes try :
# fdisk -l
you will see it there if it is...

When I checked with dmesg after plugin, the following message is display:

hub.c: new USB device 00:1d.7-6, assigned address 3
WARNING: USB Mass Storage data integrity not assured
USB Mass Storage device found at 3

Removing the thumbdrive, the message is:
usb.c USB disconnect on device 00:1d.7-5 address 3

Also, in the /proc/scsci/scsi file, it has the following entry:
Host: scsi3 Channel: 00 Id: 00 Lun: 00
   Vendor: Memorex Model: USB2 Thumbdrive   Rev: 2.00
   Type:    Direct-Access                                   ANSI SCSI revision: 02

Using the command fdisk -l only displays info about my hard disk devices.

"Host: scsi3 Channel: 00 Id: 00 Lun: 00" says that it has associated /dev/sdc with the device. So you should be able to do:

mount -t vfat /dev/sdc1 /mnt/mrexdisk

jlevie:

How do you get from "Host: scsi3 Channel: 00 Id: 00 Lun: 00"  that /dev/sdc is associated with the device?
Anyways, I tried your suggested mount command, but it still returns the same error.
In fact, previously I tries mounting with many /dev/sd*1, (where * = a, b, c and d) but none of them worked.
> How do you get from "Host: scsi3 Channel: 00 Id: 00 Lun: 00"  that /dev/sdc

SCSI disks start at sda and increment with each disk device. Since you said that you had been accessing the drive as sda1 I presumed that you don't have any other SCSI disks on the system, So scsi3 would then imply sdc.

If hotplug and the USB modules are working normally the full text (from dmesg or the contents of /var/log/messages) of a storage device attament would look similar to:

Initializing USB Mass Storage driver...
usb.c: registered new driver usb-storage
scsi1 : SCSI emulation for USB Mass Storage devices
  Vendor: NEUROS    Model: dig. audio comp.  Rev: 1.00
  Type:   Direct-Access                      ANSI SCSI revision: 02
Attached scsi removable disk sdc at scsi1, channel 0, id 0, lun 0
SCSI device sdc: 252574 512-byte hdwr sectors (129 MB)
usb-uhci.c: interrupt, status 2, frame# 29
sdc: test WP failed, assume Write Enabled
 sdc: sdc1

That clearly telly you what disk device has been associated with the device. The dmesg output you show above would seem to indicate that something isn't working right unless you've truncated the messages.

 On the system I'm using /proc/scsi/scsi contains:

Attached devices:
Host: scsi0 Channel: 00 Id: 00 Lun: 00
  Vendor: SEAGATE  Model: ST336706LW       Rev: 010A
  Type:   Direct-Access                    ANSI SCSI revision: 03
Host: scsi0 Channel: 00 Id: 01 Lun: 00
  Vendor: SEAGATE  Model: ST336706LW       Rev: 010A
  Type:   Direct-Access                    ANSI SCSI revision: 03
Host: scsi0 Channel: 00 Id: 04 Lun: 00
  Vendor: EXABYTE  Model: EXB-85058SQANXR1 Rev: 07T0
  Type:   Sequential-Access                ANSI SCSI revision: 02
Host: scsi0 Channel: 00 Id: 05 Lun: 00
  Vendor: TOSHIBA  Model: XM5701TASUN12XCD Rev: 2395
  Type:   CD-ROM                           ANSI SCSI revision: 02
Host: scsi0 Channel: 00 Id: 06 Lun: 00
  Vendor: YAMAHA   Model: CRW8824S         Rev: 1.00
  Type:   CD-ROM                           ANSI SCSI revision: 02
Host: scsi1 Channel: 00 Id: 00 Lun: 00
  Vendor: NEUROS   Model: dig. audio comp. Rev: 1.00
  Type:   Direct-Access                    ANSI SCSI revision: 02

Since the first two SCSI devices are disks (sda & sdb) , the next a tape and the two following are CD/CDRW drives my Neuros winds up being sdc (the next disk device available).

I still don't what's going on with the device.
Just more info..the complete listing of the /proc/scsi/scsi file since I last plugged in the storage drive is:

Host: scsi2 Channel: 00 Id: 00 Lun: 00
   Vendor: Memorex Model: USB2 Thumbdrive   Rev: 2.00
   Type:    Direct-Access                                   ANSI SCSI revision: 02
Host: scsi3 Channel: 00 Id: 00 Lun: 00
   Vendor: HL-DT-ST   Model: RW/DVD GCC-4480B   Rev: 1.12
   Type:    CD-ROM                                          ANSI SCSI revision: 02

The first entry is my mass storage drive and the second entry is my cd drive. What does this imply for a /dev/sd? for my storage drive?

Also, my dmesg output is the same as what I reported above in my original posting. As you can see, it does not look anything like what jlevie is reporting. So, something is wrong, but what?


I've seen this sort of behaviour before on my ThinkPad A31 with some USB storage devices. Sometimes the work, with the normal verbage as above, and sometimes all I get is the the first part of the verbage.  As ras as I've been able to determine it is some mismatch between the laptop hardware and the USB host adapter driver. i don't know if something similar might be occuring here.

Is your RHEL up to date (including the latest kernel (2.4.21-20.EL))? Have you checked to see if there's a later version of the system BIOS than what on the motherboard right now?

If you have the option, disabling PnP mode in the BIOS can help sometimes with strange problems like this.

What does /proc/scsi/scsi contain after a boot and before anything (other than a mouse or keyboard) has been attached to the USB ports? And what does it contain right after you plug in the thumbdrive?


For the longest time, my RHEL system has been working fine w/ the latest kernel. The PC does not need a BIOS upgrade.

The file /proc/scsi/scsi contains only info on my CD ROM drive on bootup. After I plug in my thumbdrive, the file /proc/scsi/scsi contains info similar to the following:

Host: scsi2 Channel: 00 Id: 00 Lun: 00
   Vendor: Memorex Model: USB2 Thumbdrive   Rev: 2.00
   Type:    Direct-Access                                   ANSI SCSI revision: 02

Since my last posting, I have the following update. I did not have another thumbdrive, so I borrowed one and plugged it into my RHEL system and mounted it. The mount was successful and and I was able to read/write to the thumbdrive. So, what's so different about my thumbdrive? I am able to read/write to it when I plug it into my Windows PCs.
RHEL recogizes a FAT file system...my thumbdrive is in FAT format.


I also want to add the following about the behavior of my thumbdrive when plugging it into my system and trying to mount it.

If I reboot my RHEL system and plug in my thumbdrive and then do a dmesg command, the following info is displayed:

hub.c: new USB device 00:1d.7-5, assigned address 2
usb.c: USB device 2 (vend/prod 0xa16/0x9903) is not claimed by any active driver.
Initializing USB Mass Storage driver...
usb.c: registered new driver usb-storage
scsi3 : SCSI emulation for USB Mass Storage devices
Starting timer : 0 0
  Vendor: Memorex   Model: USB2 ThumbDrive   Rev: 2.00
  Type:   Direct-Access                      ANSI SCSI revision: 02
Starting timer : 0 0
Attached scsi removable disk sda at scsi3, channel 0, id 0, lun 0
SCSI device sda: 512000 512-byte hdwr sectors (262 MB)
sda: Write Protect is off
 sda: sda1 sda2 sda4
WARNING: USB Mass Storage data integrity not assured
USB Mass Storage device found at 2
USB Mass Storage support registered.

After I attempt to mount it by invoking the following:

$ mount -t vfat /dev/sda1 /mnt/mrexdisk

I run another dmesg command and the additional info display is:

usb_control/bulk_msg: timeout
usb_control/bulk_msg: timeout
usb_control/bulk_msg: timeout
hub.c: USB device not accepting new address (error=-71)
usb-storage: host_reset() requested but not implemented
scsi: device set offline - command error recover failed: host 3 channel 0 id 0 lun 0
SCSI disk error : host 3 channel 0 id 0 lun 0 return code = 6050000
 I/O error: dev 08:01, sector 0
 I/O error: dev 08:01, sector 2
 I/O error: dev 08:01, sector 0
 I/O error: dev 08:01, sector 2
 I/O error: dev 08:01, sector 4
 I/O error: dev 08:01, sector 6
 I/O error: dev 08:01, sector 0
 I/O error: dev 08:01, sector 2
 I/O error: dev 08:01, sector 4
 I/O error: dev 08:01, sector 6
 I/O error: dev 08:01, sector 64
 I/O error: dev 08:01, sector 66
 I/O error: dev 08:01, sector 68
 I/O error: dev 08:01, sector 70

I have no idea what this means, other than the system is having a problem with the mount.

 
ASKER CERTIFIED SOLUTION
Avatar of jlevie
jlevie

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial