View previous topic :: View next topic |
Author |
Message |
3AndMe n00b

Joined: 15 Apr 2005 Posts: 16 Location: Pennsylvania, USA
|
Posted: Fri Apr 15, 2005 5:40 am Post subject: Assigning specific block devices to USB appliances |
|
|
Greetings, all. This is my first post on this forum. I hope this question isn't too absurd. I've tried doing a search, but I couldn't find an answer. This question probably isn't Gentoo-specific, but since I'm using Gentoo, what the heck. Here goes:
I have several USB appliances (an iPod Shuffle, an external HD, and a digital camera) that I use frequently. I can mount and use them all without a problem, however because I don't leave them plugged in (I am always randomly connecting and disconnecting the devices), I don't know how to assign block devices to each of them. My /etc/fstab entries for these devices currently look like this:
Code: |
/dev/sda1 /mnt/external reiserfs noauto,user,rw 0 0
/dev/sda1 /mnt/camera vfat noauto,user,rw 0 0
/dev/sda1 /mnt/ipod vfat sync,user,noauto,umask=000 0 0
|
As you can see, the problem here is that I can only use one device at a time. If I plug in all three devices, I can see sda1, sdb1, and sdc1 in /dev. As I unplug the appliances, the block devices disappear from /dev one by one, respectively (as they should). All fine and dandy, except I don't know how to setup my /etc/fstab with all those block devices because it depends on the order in which I plug the USB appliances in. For instance, I can't make the assumption that the external HD will always be /dev/sda1, or that the iPod will always be /dev/sdb1.
How can I set up my system to manage the ever-changing (dynamic?) block devices for the USB appliances? I want to be able to have any number of devices plugged in at any given time, in any order, and still have valid fstab info for each so that I can mount them just by clicking on the device shortcuts I have on my deskop. I don't want to have to manually "mount -t blah blah blah /dev/sdX /mnt/XXX" each time for each device.
I figure if I can just plug in and use my USB appliances in Windows, I should be able to do it in Linux too, right???
For reference, my system is running 2.6.8-gentoo-r3. USB drivers are modular. I am not using udev or hotplug (I prefer to keep it like that, for now). _________________ My Gentoo is broken again. |
|
Back to top |
|
 |
acasto Apprentice


Joined: 06 Feb 2004 Posts: 236 Location: Durka-Durka-Stan
|
Posted: Fri Apr 15, 2005 7:11 am Post subject: Re: Assigning specific block devices to USB appliances |
|
|
3AndMe wrote: | I am not using udev or hotplug (I prefer to keep it like that, for now). |
Why not switch to UDEV? There's plenty of excellent Gentoo manuals and it will do all your talking about above.
- Adam _________________ Leerrroooooyyyyyyyy JENKINS!!!!1111...................
"You know the Nazi's had pieces of flare.. that they made the Jews wear." |
|
Back to top |
|
 |
3AndMe n00b

Joined: 15 Apr 2005 Posts: 16 Location: Pennsylvania, USA
|
Posted: Fri Apr 15, 2005 7:19 am Post subject: |
|
|
^^^
Mainly because I have no experience with it. I don't know what would change because of it, and that kind of scares me because it took me long enough to get used to the system and how to administer it as it is. I would like to look into udev at some point, and if need be, I'll look into it much sooner if that will solve my problem like you suggest. If there is a way to do it without udev though, I'd be more than happy to know.
I'll take a look at the Gentoo docs on udev as soon as I get some time. _________________ My Gentoo is broken again. |
|
Back to top |
|
 |
3AndMe n00b

Joined: 15 Apr 2005 Posts: 16 Location: Pennsylvania, USA
|
Posted: Sat Apr 16, 2005 12:34 am Post subject: |
|
|
*bump*
Any gurus on here know if what I'm looking to do is possible without udev? _________________ My Gentoo is broken again. |
|
Back to top |
|
 |
phsdv Guru


Joined: 13 Mar 2005 Posts: 372 Location: Europe
|
|
Back to top |
|
 |
3AndMe n00b

Joined: 15 Apr 2005 Posts: 16 Location: Pennsylvania, USA
|
Posted: Sun Apr 17, 2005 2:18 am Post subject: |
|
|
Thanks for the link. _________________ My Gentoo is broken again. |
|
Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|