grub-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] don't abort with error if realpath fails


From: Yoshinori K. Okuji
Subject: Re: [PATCH] don't abort with error if realpath fails
Date: Fri, 22 Sep 2006 07:42:38 +0200
User-agent: KMail/1.8.2

On Thursday 21 September 2006 19:34, Robert Millan wrote:
> Sure.  The purpose of realpath here isn't really to verify device
> existance; that ought to happen later if (and only if) we're actualy going
> to use that device.
>
> Suppose this device.map:
>
> (hd0) /dev/hda
> (xxx) /dev/idontexist
>
> Theoricaly, when grub-setup is told to act on (hd0) it shouldn't care that
> /dev/idontexist doesn't exist (it could be listed because it was generated
> by an older grub, because the device disappeared, etc).  However, because
> of the realpath canonicalisation, as a collateral result we get to abort if
> _any_ of the entries are wrong:

I understand what you mean. Thank you.

> My point is that grub should be fault tollerant and not care that
> /dev/idontexist is broken, specialy since device.map is a file that is
> subject for input from either user or older grub (including grub legacy),
> and we have little control about its contents.

I describe my own opinion here. GRUB itself must be extremely fault-tolerant, 
as the user cannot boot up a machine if GRUB fails. However, the installer of 
GRUB must be extremely error-sensitive, as the user cannot boot up a machine 
if the installation happens _wrongly_. If a device map contains any error, 
it's likely that the user made some mistake or skip over erroneous 
information. Personally I much, much prefer that GRUB is not installed in 
this case. Failing in installing GRUB is better than making a machine 
unbootable.

Okuji




reply via email to

[Prev in Thread] Current Thread [Next in Thread]