[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Bug#352753: udev: ide-generic no longer loaded on boot

On Wed, 15 Feb 2006, Marco d'Itri wrote:

> On Feb 14, Frans Pop <aragorn@tiscali.nl> wrote:
> > We've done a debugging session today involving Otavio Salvadore (who also 
> > saw the issue), maks and myself.
> > 
> > There are two possible solutions, both involving modifications in
> > /usr/share/initramfs-tools/hooks/udev.
> > 
> > 1) revert inclusion of *_id scripts
> >    Commenting out the three lines at the end of the current file lets the
> >    system boot again.
> > 2) add 'copy_exec /lib/udev/ide.agent /lib/udev' at the end of the file
> >    Apparently some _id script calls ide.agent and this makes sure
> >    ide-generic is loaded at the correct time.
> So far there has not been a relevant progress then.

mumbling, i'm all ears for working solutions.

> The first solution is obviously unacceptable because supporting
> persistent disk names in the initramfs has been a planned feature since
> they were designed.

but reverting them now would have been not so bad,
as they were only added since a short while.

> The second solution means that I would need to add to my package code
> whose purpose I do not understand (which systems do need ide-generic,
> when and why?). 

the patch simply adds existing ide.agent to the initramfs.
no change to your code.

> Also, I cannot see any way for the *_id programs
> called by persistent.rules to prevent init-premount/ide, which contains
> an unconditional "modprobe -q ide-generic", to load the module.
> This is too much close to cargo cult programming for my taste.

this needs refactoring, will be done soon similar to the ubuntu hook,
loading it only for ide boots. this point is out of discussions.

your current initramfs hook breaks too many boxes,
really looking forward to a fixed udev hook soon.

> > Basically ide.agent does the same as what's currently in
> > /usr/share/initramfs-tools/scripts/init-premount/ide (which could probably 
> > be cleaned now).
> What happens if you rearrange your initramfs to run this script before
> the udev script instead of later? If you are right and ide-generic needs
> to be loaded before other drivers (which is totally broken and is not
> something udev would support) then this would be the correct fix.

nahh loading ide-generic too early removes the dma possibilities of many
ide boxes.
> BTW, I would really really like to see the content of an uevent which
> causes ide-generic to be loaded.

sure that would be nice, but you are currently breaking previously
working setups. we can always investigate that later.
> I fully agree, but I need to find a clever way to do it. Can you suggest
> ways for udevd to detect if it's running in an initramfs?
> Like checking for a specific environment variable or a file.
> > maks suggested to re-add the "silence_exec_error" patch for Beta2 and 
> > maybe come back to this issue after that?
> Maybe, but I'd rather to fix this once for good instead of hiding all
> errors again.

we don't set an specific env variable,
but there is a state directory in /dev/.initramfs
you can check for -d /dev/.initramfs


Reply to: