Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Confused about partitions and USB storage
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
mattsavigear
Apprentice
Apprentice


Joined: 08 Jan 2003
Posts: 224
Location: Wales, UK

PostPosted: Thu Jun 24, 2004 10:28 pm    Post subject: Confused about partitions and USB storage Reply with quote

I have a several-in-one card reader on my machine. Right now it comes up as sda and sdb (there are two luns on the device, one for CF and microdrives, the other for SD, SM and so on), as well as the corresponding /dev/sd/c2b0t0u0 and c2b0t0u0.

Now, I can try to mount /dev/sd/c2b0t0u0, which fails as expected, however after the mount attempt, I then have a device for the partition created, /dev/sd/c2b0t0u0p1 (and /dev/sda1), which I can mount.

So, I have a question - is there a way to avoid the initial failed mount attempt which is currently required to cause the partition device to be created? I don't actually want the cards to automount themselves, I just want the partitions to be automatically available to me to manually mount should I insert a card.

In case it's important I'm using ehci_hcd built into my 2.6.7-mm kernel.
_________________
Matt.

"Ninjas aren't dangerous. They're more afraid of you than you are of them." - The Tick.
Back to top
View user's profile Send private message
diastelo
Guru
Guru


Joined: 23 Feb 2004
Posts: 521

PostPosted: Fri Jun 25, 2004 12:15 am    Post subject: Reply with quote

Are you using devfs or udev? Devfs and udev both handle creating devices "dynamically", but they do it in different ways. Udev is the newer and better standard out there right now, while devfs is the tried and true.

Have you tried mounting /dev/sda1 or /dev/sdb1 without waiting for the device to appear? It may be enough to trigger it to work.
_________________
"No question is so difficult to answer as that to which the answer is obvious" -- George Bernard Shaw
Back to top
View user's profile Send private message
mattsavigear
Apprentice
Apprentice


Joined: 08 Jan 2003
Posts: 224
Location: Wales, UK

PostPosted: Fri Jun 25, 2004 10:12 am    Post subject: Reply with quote

Currently devfs (assuming that's the default for a recent Gentoo install), though I might look into udev over the weekend. To be honest, I need to look into these topics anyway - I haven't a clue what the /sys directory is all about and whether that should be useful, or is that actually part of udev?

Time for some research I feel.

Oh, and I tried mounting sda1 and so on before they appear, but it fails.
_________________
Matt.

"Ninjas aren't dangerous. They're more afraid of you than you are of them." - The Tick.
Back to top
View user's profile Send private message
diastelo
Guru
Guru


Joined: 23 Feb 2004
Posts: 521

PostPosted: Mon Jun 28, 2004 12:39 am    Post subject: Reply with quote

/sys is required for udev to work. Having it there without udev installed won't accomplish much, but it won't hurt anything either.

If you want to take the plunge and try udev, Gentoo is an excellent place to try it. There's a system in place that will let you switch between udev and devfs at boot. If you browse through the forums, you might be able to find others who have come up with solutions to your problem with udev. Someone has even kindly created a guide to getting Udev up and running (http://www.gentoo.org/doc/en/udev-guide.xml). Hope this helps.

In the meantime, have you tried putting the card in the reader, then plugging it into the computer? Maybe if the card is already in the device, it will trigger devfs into recognizing the partitions earlier.
_________________
"No question is so difficult to answer as that to which the answer is obvious" -- George Bernard Shaw
Back to top
View user's profile Send private message
mattsavigear
Apprentice
Apprentice


Joined: 08 Jan 2003
Posts: 224
Location: Wales, UK

PostPosted: Mon Jun 28, 2004 8:35 am    Post subject: Reply with quote

Well, I've got udev up, and now I'm researching what to actually do with it. I can't plug and unplug the device, BTW, as it's internal.
_________________
Matt.

"Ninjas aren't dangerous. They're more afraid of you than you are of them." - The Tick.
Back to top
View user's profile Send private message
diastelo
Guru
Guru


Joined: 23 Feb 2004
Posts: 521

PostPosted: Tue Jun 29, 2004 12:10 am    Post subject: Reply with quote

Peripherals are so much simpler when they're external. Oh well. In any case then, modify my last suggestion to read "boot your computer with the memory already in the device" and see if that accomplishes anything.

There was this fairly large thread that I've lost track of a while back called "I have udev installed, now what?". I did a quick search for it, and I haven't found it, but I'm a little slow today (Mondays, you know), so feel free to take another look. It might be up your alley.
_________________
"No question is so difficult to answer as that to which the answer is obvious" -- George Bernard Shaw
Back to top
View user's profile Send private message
Decibels
Veteran
Veteran


Joined: 16 Aug 2002
Posts: 1630
Location: U.S.A.

PostPosted: Tue Jun 29, 2004 1:20 am    Post subject: Reply with quote

Got Udev working, now what?
https://forums.gentoo.org/viewtopic.php?t=115096&highlight=

Udev Primer
http://webpages.charter.net/decibelshelp/LinuxHelp_UDEVPrimer.html
_________________
Support bacteria – they’re the only culture some people have.”

– Steven Wright
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
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