LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
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 03-11-2004, 09:52 AM   #1
Lobais
Member
 
Registered: Jan 2004
Location: Denmark
Distribution: Fedora Core 6
Posts: 224

Rep: Reputation: 30
How to mount a memory bird?


How do I mount my memory bird to the usb? Does it require any special drivers/software?
 
Old 03-11-2004, 12:05 PM   #2
b0uncer
LQ Guru
 
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
I guess you need the modules called "usb-storage" and perhaps "uhci-hcd", and maybe (not sure) "usbserial" in your kernel?

try with modprobe, if they aren't compiled into the kernel (I don't think so)

modprobe usb-storage
modprobe uhci-hcd
modprobe usbserial

(I'm not sure which of those you need...I have several usb devices, and they need those at least)

after this, when the correct modules are loaded and you plug your usb-memory in, a device called "sdaX" should appear in /dev where X in the name is a number (I have sda4 for example, which is my usb-memory stick). just mount it normally and you should be able to use it...and remember to umount it before unplugging it (it's more than important if you wish to keep your data safe)!

if it works, just add the modules you modprobed, to a file/configuration which probes them automatically at bootup.
 
Old 03-14-2004, 09:55 AM   #3
Lobais
Member
 
Registered: Jan 2004
Location: Denmark
Distribution: Fedora Core 6
Posts: 224

Original Poster
Rep: Reputation: 30
I think the first thing was done good.
Code:
# modprobe usb-storage
# modprobe uhci-hcd
modprobe: Can't locate module uhci-hcd
# modprobe usbserial
#
but the second thing didn't I understand. Cant I just say something like
Code:
mount /dev/usb
?
 
Old 03-14-2004, 01:29 PM   #4
b0uncer
LQ Guru
 
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
ok, now we need to know what the device is called... I can't remember right now a simple technique for this (tired...got an exam tomorrow..), but in the meantime you can try this:

1) create a new folder to your /mnt directory, say /mnt/mem so that we can mount the device there (and use the folder we create as the place where we deal with the files in the device)

2) issue the following command (after you've plugged the usb-memory to your usb port and modprobed the modules)

Code:
mount /dev/sda1 /mnt/mem
and if no error msgs pop up, check out if you got something into /mnt/mem (or if some led on your device blinks). now, if this doesn't happen, try out sda2, sda3, sda4 (mine is sda4, for some reason) etc., if some of them might work (ok, this is just a blind shooting, but if you got nothing else to do before I remember the more simple way, you may try.. heh)

like

Code:
mount /dev/sda2 /mnt/mem
mount /dev/sda3 /mnt/mem
mount /dev/sda4 /mnt/mem
(note that you might have to be root to do this) now if you happen to have no error messages after a mount, then this possibly worked out and you just found the device. try out and after each try, see (if you have some files on the memory) whether you get something into /mnt/mem....

I recall that in /proc there was a file, where a new line is appended after you plug the memory in, telling (kind of a logfile) that it is seen...but can't remember which one :/ I try to check this out tomorrow if I have time, so if you aren't in a hurry, you may not to try blindly mounting the devices... but: before plugging the thing in the first place, see how many sdaX (where X is a number) device files you have in /dev and after plugging, check if you got one more. if you did, then it should be it...altough for me have many of them even if my stick isn't plugged...

sorry for the long explanation. I'll try to collect my information tomorrow for you in a short, understandable way...

Last edited by b0uncer; 03-14-2004 at 01:33 PM.
 
Old 03-15-2004, 09:34 AM   #5
b0uncer
LQ Guru
 
Registered: Aug 2003
Distribution: CentOS, OS X
Posts: 5,131

Rep: Reputation: Disabled
ok, here I am back again....hopefully with something helpful this time

at first, let's do a little test; when you have _not_ plugged the usb memory in, issue the following command in terminal (cd into the proc dir specified):

Code:
cd /proc/scsi/usb-storage
ls
and probably you should get absolutely no output (heh..interesting?). now plug in the memory and do (yes, in the same terminal in the same dir as above)

Code:
ls
now if you got something new there, some number for instance, it should be your usb memory on my PC, I got "5" there, but I'm not sure what you get. anyway, if you did get something there, then:

Code:
cat X
where X is the newly found thing you got in the directory (you saw it above with the ls command if it appeared...if not, then we got a little problem). see the output and it should describe your memory... I'm pretty sure the file should pop up into this dir when you plug the memory in.

BUT - if you didn't get the file here: do the same experiment with other usb directories in your /proc and see if it's somewhere else. if not, then we might miss a module from the kernel. again, if we miss a module, I'd say it's the uhci-hcd or ohci-chd, and it can be added either by recompiling the kernel from sources or trying to install it with insmod (I have never used/needed insmod, but I guess it should work like this?)

Code:
locate uhci-hcd
insmod /AAA/BBB/CCC/uhci-hcd.X
where /AAA/BBB/CCC/uhci-hcd.X is the complete path for the module, which you should get from the "locate" command if it exists. otherwise, we might need the recompilation. you must be root to do this.

now, if you _did_ get the file in your /proc , then we have the device. now let's see where we have it.... again, in terminal, issue this:

Code:
dmesg | grep USB | more
and you should get the scsi-device related lines (if nothing appears, try changing the "USB" in the line to "usb" or something, of course without quotes). what I get is like this:

Code:
dmesg | grep USB | more
<-----some output cut off----->
usb 1-2: Product: USB 2.0 Memory Adapter 
scsi3 : SCSI emulation for USB Mass Storage devices
  Vendor: USB 2.0   Model: Memory Adapter    Rev:
<-----some output cut off----->

dmesg | grep SCSI | more
scsi3 : SCSI emulation for USB Mass Storage devices
  Type:   Direct-Access                      ANSI SCSI revision: 02
SCSI device sda: 251904 512-byte hdwr sectors (129 MB)
now from the above I see "SCSI device sda" which tells me, that the device is called sda, so in /dev/ there is some kind of sdaX (where X is number) that is my memory stick. and when I issue

Code:
ls /dev/sda*
I get only sda and sda4, from which the sda4 is the correct. so seek a line like mine above, where you can read "XXX device yyy" where yyy should be the device name you need

hopefully you didn't sleep while reading....this is quite long text. but hopefully helps...if you can't find it, you might need to add the uhci-hcd to your kernel if it doesn't have it (you said it didn't modprobe it?)....that means, either insmod it (check in terminal: man insmod) or then recompile the kernel from source.... (that's not as bad as it sounds)

Last edited by b0uncer; 03-15-2004 at 09:48 AM.
 
Old 03-19-2004, 12:55 AM   #6
Lobais
Member
 
Registered: Jan 2004
Location: Denmark
Distribution: Fedora Core 6
Posts: 224

Original Poster
Rep: Reputation: 30
Code:
$ ls
scsi  sg  usb-storage-0
$ cd usb-storage-0
$ ls
0
$
The "0" file contains:
Host scsi0: usb-storage
Vendor: FSC
Product: MEMORYBIRD USB2
Serial Number: J426271825060315AA
Protocol: Transparent SCSI
Transport: Bulk
GUID: 05dc02002718250ffffffff9
Attached: Yes

The Attached thing could be my usb mouse...

Code:
# updatedb
# locate uhci-hcd
#
Do you think it's the kernel thing?

Last edited by Lobais; 03-19-2004 at 01:03 AM.
 
Old 03-31-2004, 09:32 AM   #7
Lobais
Member
 
Registered: Jan 2004
Location: Denmark
Distribution: Fedora Core 6
Posts: 224

Original Poster
Rep: Reputation: 30
Ah, I've found something.
http://www.extremeoverclocking.com/r...SBDrive_2.html
I haven't tested it (I have lent my usbkey for one of my friends) but it brings something new.
Code:
#mkdir /mnt/usbkey
 
  


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
How to mount a memory stick davidsrsb Slackware 8 09-09-2004 08:33 PM
How to mount usb flash memory tony2666 Linux - Hardware 2 05-25-2004 07:31 AM
mozilla fire bird herbert Red Hat 4 10-23-2003 01:46 PM
humming bird exceed alternatives calble Linux - Software 1 08-07-2003 01:20 PM
This is soooo coooool, penguin is my favorite bird neo77777 General 6 05-31-2003 04:12 PM

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

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