Re: current linus bk, error mounting root

From: Greg KH
Date: Mon Mar 21 2005 - 19:47:40 EST


On Mon, Mar 21, 2005 at 04:19:25PM -0800, Andrew Morton wrote:
>
> (Adds lots of cc's. I trust that's OK).
>
> Jon Smirl <jonsmirl@xxxxxxxxx> wrote:
> >
> > No, I think Jens wants all of the distributions to fix it. I have
> > filed a bug with Fedora on it.
> >
> > Something changed in the timing for loading drivers during boot. You
> > used to be able to do:
> > modprobe ata_piix
> > mount /dev/sda1

You can't do that on any udev based system reliably. That has _never_
been true. You might just have been getting lucky in the past.

> > Now you have to do this:
> > modprobe ata_piix
> > sleep 1
> > mount /dev/sda1

That's still racy. Rely on the /etc/dev.d/ notifier to be able to tell
you when you can mount your device, that is what it is there for.

This is a udev issue, not a kernel issue, there's nothing we can do in
the kernel about it (well, except for the obvious thing of giving udev
lots of hints and making it easier for it to work properly and faster,
which we have been doing over the past months.)

> > I suspect the problem is that udev doesn't get a chance to run anymore.
> > The sleep 1 allows it to run and it creates /dev/sda1.
> > Build ata_piix in and the problem goes away too.
> >
> > Jens is right that this is a user space issue, but how many people are
> > going to find this out the hard way when their root drives stop
> > mounting. Since no one is complaining I have to assume that most
> > kernel developers have their root device drivers built into the
> > kernel. I was loading mine as a module since for a long time Redhat
> > was not shipping kernels with SATA built in.
>
> I don't agree that this is a userspace issue. It's just not sane for a
> driver to be in an unusable state for an arbitrary length of time after
> modprobe returns.

It is a userspace issue. If you have a static /dev there are no
problems, right? If you use udev, you need to wait for the device node
to show up, it will not be there right after modprobe returns.

thanks,

greg k-h
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/