public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: Erik Steffl <steffl@bigfoot.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: udev and /dev/sda1 not found during boot (it's there right after boot)
Date: Sun, 23 May 2004 21:58:54 -0700	[thread overview]
Message-ID: <20040524045853.GA27216@kroah.com> (raw)
In-Reply-To: <40B16C16.9000203@bigfoot.com>

On Sun, May 23, 2004 at 08:29:26PM -0700, Erik Steffl wrote:
>   I was hoping for something that would shed some light on _why_ this 
> happens on my (debian) system. The fact that it doesn't happen on your 
> systems that happen to be non-debian doesn't mean much... because I 
> don't see anything debian specific in debian package (which is the same 
> thing debian maintainer wrote, see link below).

It's all up to the init scripts, which are _very_ distro specific.

>   it looks like the problem is that after the modprobe is done the 
> device is still not available. that _seems_ like a serious problem of 
> udev.

No, it's not a serious problem.  The device will show up soon, but it's
not available _right_ after modprobe returns.  A lot of async events
need to happen before the node shows up.  That is the main change a lot
of different init scripts in distros have had to accommodate (alsa is
one specific example of this.)

> Maybe I am missing something but after the modprobe is done and 
> reports success

Wait, how does modprobe report success?  All it can return is if the
module loaded or not.  Not if a device actually was bound to that driver
or not (see the thread on lkml a week or so ago about how you can
determine this if you really want to.)

Lots of stuff happens in the kernel after modprobe returns successfully,
and for some kinds of drivers the device is not set up until a
measurable amount of time afterwards.

> the device should be available, ortherwise the programs 
> have no way to find out what's going on. Adding random sleeps (for how 
> long?) doesn't seem like a solution.

Don't randomly sleep, smartly sleep.  Sleep until you see the device
node you care about, or you time out after some longer amount of time
has gone by.  That's all that is needed to change in your init script
package.  As I don't run Debian on any of my boxes anymore, I really
can't be of much help here to try to debug this and change the proper
one to work in this manner.

So to summarize:
	- this isn't a kernel issue (so why talk about it on lkml?)
	- this isn't a udev issue (it creates the node as fast as it is
	  told to.)
	- this _is_ a startup script issue.  Please go bug your distro
	  to fix it in the manner described above.

Hope this helps,

greg k-h

      reply	other threads:[~2004-05-24  4:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-24  7:37 udev and /dev/sda1 not found during boot (it's there right after boot) Erik Steffl
2004-04-24 15:55 ` Greg KH
2004-04-24 20:32   ` Marco d'Itri
2004-05-23 15:56   ` Erik Steffl
2004-05-23 16:25     ` Greg KH
2004-05-24  3:29       ` Erik Steffl
2004-05-24  4:58         ` Greg KH [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20040524045853.GA27216@kroah.com \
    --to=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=steffl@bigfoot.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox