[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
grub-install
From: |
Yoshinori K. Okuji |
Subject: |
grub-install |
Date: |
Sun, 24 Jul 2005 20:44:19 +0200 |
User-agent: |
KMail/1.7.2 |
I have mostly implemented grub-install as a shell script. I just copied it
from GRUB Legacy then adapted it to GRUB 2. This script is much simpler in
GRUB 2, because grub-setup handles most things.
It has one remaining issue, and I'm not sure what is appropriate for this.
Since the core image in GRUB 2 is generated dynamically, it is necessary to
specify what modules should be included in it. When the user uses
grub-install, I believe that they should be automatically determined.
For now, pc.mod and _chain.mod are hardcoded. I think these are good enough
for PC. It might be better to add _linux.mod on GNU/Linux, though. I'm not
sure.
The issue is how to determine a filesystem module which is needed to load more
modules. I think there are three ways:
1. Shell scripting. Probably it is possible to write a shell function which
detects a filesystem by using df, mount, etc. I do not like this approach
very much, because the installation environment can be very minimalistic
(suppose when you install an OS using a floppy), and the behaviors of
commands are sometimes not clever enough.
2. Adding an option into grub-mkimage to add a filesystem module
automatically, depending on the filesystem of a grub directory. This is not
bad, but this makes grub-mkimage a bit complex.
3. Adding a new utility which detects an appropriate filesystem module for a
given directory. This is not bad, but this sounds a bit overkill.
What do you think?
Okuji
- grub-install,
Yoshinori K. Okuji <=
- Re: grub-install, Hollis Blanchard, 2005/07/24
- Re: grub-install, Hollis Blanchard, 2005/07/25
- Re: grub-install, Marco Gerards, 2005/07/25
- Re: grub-install, Yoshinori K. Okuji, 2005/07/25
- Re: grub-install, Vincent Pelletier, 2005/07/26