Re: Grub Installation Mini How-To
- From: imotgm <imotgm_REM@xxxxxxxxxxxxxxxxx>
- Date: Thu, 15 Dec 2005 09:38:26 GMT
On Thu, 15 Dec 2005 03:18:15 +0100, Enrique Perez-Terron wrote:
> On Thu, 15 Dec 2005 02:14:45 +0100, imotgm <imotgm_REM@xxxxxxxxxxxxxxxxx> wrote:
>
>> info:grub <Enter>
>
> Obviously, in an ordinary console window, the command is
>
> info grub <Enter>
But if you do that in konqueror, you get a google search. ;-)
>
> [...]
>
>> Drive mapping, in the form of a Windows stanza as such,
>>
>> title Windows
>> root (hd1,0)
>
> Isn't this "rootnoverify" ? My remarkably unreliable memory says I had
> a problem with that once... Oh, that was perhaps a an NTFS partiton!
> Anyone knows?
"rootnoverify" is for when you point grub at a part of a disk that is
beyond that which grub can read. Grub can obviously read the first sector
of the first partition of a disk. I've never had a problem with this with
Win98 on a Fat32 partition, or Win2K with NTFS. I've never, believe it or
not, even seen a WinXP installation running, yet alone had one installed,
but I've told numerous people to do this with XP, and all have reported
that it works just fine, just like Win2K. On the other hand,
"rootnoverify" won't hurt anything, so if it makes you feel better, have
at it.
>
>> map (hd1) (hd0)
>> map (hd0) (hd1)
>> makeactive
>> chainloader +1
>
> [...]
>
>> By the way, I learn as much from helping others fix their grub installs as
>> I do from my own experiments. While looking at info: grub, just now, as
>> I'm writing this for you, I see there's been some changes that I was
>> unaware of.
>
> That is exaclty how it works for me too.
>
>
> Besides, I have never been very happy with the documentation. When I read it,
> for some reason I don't fully understand, I always have a feeling of not
> knowing what is meant. It's like with the "map" command, once I had a case
> where I was never able to boot a windows partition, and I never figured
> out what was wrong. Since the partition wasn't on the first disk, I
> thought I should try the map command. Of course I tried the example in
> the manual, but it did not work, and then I read the info page more
> carefully, but the text really does not answer any question you may have.
>
> At what point does it take effect? Why do I need both
>
> map (hd1) (hd0)
>
> and
>
> map (hd0) (hd1)
>
> ?
Basically, as near as I can tell, the thinking is that if you map (hd1) to
(hd0) you now have the possibility of a poorly written BIOS to see two
(hd0)s if you don't also remap (hd0) to (hd1). Lilo has used the boot
mapping in pairs also, but now has the single commands boot as=0x80
and master-boot. There may be something going on in the background to
complete the pair, but on the surface, it's single, and quicker.
>
> Why does not the latter simply reverse the effect of the first one?
> etc. In the end I read the source code, and found that map does not
> take effect until you give the "boot" command. At that point it installs
> some code that hook's into the "int 13H" instruction, which is used
> to call the Bios disk operations. This code uses a small table to
> translate the disk number in the "int 13h" request, and then it calls
> the original "int 13h" handler. The map command specifies entries in
> this table. Finally piece in mind.
>
> I used to feel unsure about when the info page is talking about the
> grub Linux command, and when is it talking about the Grub native
> command. Looking in "Installing Grub natively", almost nothing is
> documented. The options to the setup command that appear in
> grub-install are not documented. And in grub-install, what is
> --root-dir? Oh, yes it's the root dir! But what the heck is that???
> When do you use that? I had to read the grub-install
> code to find out. And, my fool, I have already forgotten much of
> what I found out. But now I can google for much of it, because
> I wrote about it here (in earlier posts).
See what you started. Now it can come back and bite you.
>
> When everything just works, it is OK to have a rather short recipe.
> If necessary d/l and install the RPM (sw package). Then run grub-intall.
> Presto.
>
> But when you need to research what is going wrong, or you want to figure
> out how to achieve something unusual, then you need to know, e.g., where
> are the stage1_5 files installed during setup? What is the mission of
> stage1_5? Where does Grub actually load stage2 from during boot? How
> does it know? etc.
For the most part, it doesn't actually install stage1_5 unless it's
commanded to embed it. The most common thing is to install stage1 in the
MBR, and read stage1_5, and 2, from the files in /boot/grub. Stage1 can't
read file systems, which is why it must be told where to find stage1_5.
Each of the stage1_5 files can read 1 file system, so stage1 asks, "Anyone
know where we're at?" and marries the one that says "Yes". Once it can
read the fs, it searches for, and finds, stage2, and is complete. Only
then does it put up the menu, and wait to be told, by selection, which
kernel to load, or load the default when the timer runs out.
--
imotgm
"Lost? Lost? I've never been lost... Been a tad confused for a
month or two, but never lost."
.
- References:
- Re: Grub Installation Mini How-To
- From: Enrique Perez-Terron
- Re: Grub Installation Mini How-To
- From: Yves Bellefeuille
- Re: Grub Installation Mini How-To
- From: imotgm
- Re: Grub Installation Mini How-To
- From: Yves Bellefeuille
- Re: Grub Installation Mini How-To
- From: imotgm
- Re: Grub Installation Mini How-To
- From: Enrique Perez-Terron
- Re: Grub Installation Mini How-To
- Prev by Date: Re: Fedora Core 2/Windows XP dual boot: selecting Linux doesn't work
- Next by Date: Re: reinstalling grub
- Previous by thread: Re: Grub Installation Mini How-To
- Next by thread: Re: Grub Installation Mini How-To
- Index(es):
Relevant Pages
|