On Sun, 21 Oct 2007, William Case wrote: > I have been scratching around as well. I came up with more new > questions than answers. But it seems to me that understand GRUB, it > has to be completely disambiguated (to borrow a Wikipedia term) from > Linux or any other Operating System first. Only then adding in how > Linux gets loaded. quite right -- this goes back to my earlier suggestion that you need to be careful to distinguish where GRUB stops and the OS starts, and not confuse the two. > That means understanding the following in their proper order: > 1) BIOS in general > 2) How BIOS originally writes disk and partition locations to the MBR > or after installing a new harddisk. It must have some BIOS info even if > 'fdisk', 'parted' or 'mkfs' are used as part of the installation. I > don't know if these are even involved but I plan to check. > 3) What code system it uses to designate disks and partitions. I have > found three or four sites that break down the meaning of binary code bit > by bit. That needs study. i'm not sure you need to dig into the BIOS in that kind of detail -- just assume it Does The Right Thing (TM) to get you to the MBR and start executing whatever boot code it finds there because, really, that's where the fun starts. > 4)How to install Grub on a cd-rw. That will separate the men from the > boys and explain how BIOS finds GRUB and how GRUB finds the operating > system. It should also explain how stage 1.5 gets where it is going. it had already occurred to me that one handy way to see what was happening was to be able to run /sbin/grub-install and *simulate* an actual installation by giving a *regular* file as the install destination, then use "hexdump" or something to see what ended up in that regular file. if you look at the options to grub-install, you see: $ grub-install --help Usage: grub-install [OPTION] install_device Install GRUB on your drive. -h, --help print this message and exit -v, --version print the version information and exit --root-directory=DIR install GRUB images under the directory DIR instead of the root directory ... ok, so what about trying to install GRUB while 1) giving a garbage regular file as the install_device, and 2) dumping the GRUB images into yet another garbage temp directory? a quick test shows that grub-install is not so easily fooled as it verifies that the install file is an actual device file, but i'm betting it wouldn't take more than a quick tweak to the grub-install script to override that. perhaps even an additional option that allows the user to override that check, just for the fun of it. *then* you'd see what the actual effect of a grub installation was, no? rday -- ======================================================================== Robert P. J. Day Linux Consulting, Training and Annoying Kernel Pedantry Waterloo, Ontario, CANADA http://crashcourse.ca ========================================================================