Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

GRUB autoload image

10 views
Skip to first unread message

Jim

unread,
Aug 10, 2004, 4:49:12 PM8/10/04
to
Hi

I have grub installed on my box. After rebooting, I get presented with
the grub> shell. I can run the kernel/initrd/boot commands and boot the
system or run configfile /grub/menu.lst and get the menu. The problem
I'm having is I'd like the menu to automagically load (and it won't).
What do I need to do? Here are my partitions:

# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/sdb5 1.9G 209M 1.6G 12% /
/dev/sda1 38M 24M 12M 65% /boot
none 1008M 0 1008M 0% /dev/shm
/dev/sdb3 1.9G 1.2G 732M 61% /usr
/dev/sdb2 1.9G 332M 1.5G 18% /var

# fdisk /dev/sda
Command (m or help): p

Disk /dev/sda: 255 heads, 63 sectors, 8923 cylinders
Units = cylinders of 16065 * 512 bytes

Device Boot Start End Blocks Id System
/dev/sda1 * 1 5 40131 83 Linux

Here are the commands I've issued:

grub> root (hd0,0)
Filesystem type is ext2fs, partition type 0x83

grub> setup (hd0)
Checking if "/boot/grub/stage1" exists... yes
Checking if "/boot/grub/stage2" exists... yes
Checking if "/boot/grub/e2fs_stage1_5" exists... yes
Running "embed /boot/grub/e2fs_stage1_5 (hd0)"... 22 sectors are
embedded.
succeeded
Running "install /boot/grub/stage1 d (hd0) (hd0)1+22 p
(hd0,0)/boot/grub/stage
2 /boot/grub/grub.conf"... succeeded
Done.


Here's my /boot/grub/menu.lst:

# more /boot/grub/menu.lst
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this
file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/sdb5
# initrd /initrd-version.img
boot=/dev/sda
default=0
timeout=15
#splashimage=(hd0,0)/grub/splash.xpm.gz
title Red Hat Linux (2.4.20-28.7smp)
root (hd0,0)
kernel /vmlinuz-2.4.20-28.7smp ro root=/dev/sdb5 console=ttyS0
initrd /initrd-2.4.20-28.7smp.img
title Red Hat Linux (2.4.20-28.7)
root (hd0,0)
kernel /vmlinuz-2.4.20-28.7 ro root=/dev/sdb5 console=ttyS0
initrd /initrd-2.4.20-28.7.img

Why don't I get the menu (and subsequently, the autoloading of the
kernels)? Thanks.

Jim

Dances With Crows

unread,
Aug 10, 2004, 7:40:59 PM8/10/04
to
On Tue, 10 Aug 2004 16:49:12 -0400, Jim staggered into the Black Sun and
said:

> I have grub installed on my box. After rebooting, I get presented
> with the grub> shell. I can run the kernel/initrd/boot commands and
> boot the system or run configfile /grub/menu.lst and get the menu.
> The problem I'm having is I'd like the menu to automagically load (and
> it won't). What do I need to do?

So, your config file is in /boot/grub/menu.lst ? That's where it's
supposed to be, though on my system with GRUB 0.92, menu.lst is a
symlink to grub.conf .

> /dev/sda1 38M 24M 12M 65% /boot

> grub> root (hd0,0)


> grub> setup (hd0)
> Checking if "/boot/grub/stage1" exists... yes
> Checking if "/boot/grub/stage2" exists... yes
> Checking if "/boot/grub/e2fs_stage1_5" exists... yes
> Running "embed /boot/grub/e2fs_stage1_5 (hd0)"... 22 sectors are
> embedded. succeeded
> Running "install /boot/grub/stage1 d (hd0) (hd0)1+22 p
> (hd0,0)/boot/grub/stage2 /boot/grub/grub.conf"... succeeded

This all looks OK.

> # more /boot/grub/menu.lst
> boot=/dev/sda

I don't have a boot= line in my grub.conf . I don't even think it's a
supported configuration option, though obviously it works if you specify
the config file manually.

> default=0
> timeout=15


> title Red Hat Linux (2.4.20-28.7smp)
> root (hd0,0)
> kernel /vmlinuz-2.4.20-28.7smp ro root=/dev/sdb5 console=ttyS0
> initrd /initrd-2.4.20-28.7smp.img
>

> Why don't I get the menu (and subsequently, the autoloading of the
> kernels)? Thanks.

This should all work properly. Try removing the boot= line, and post
the output of grub --version... versions older than 0.92 may have some
weird quirks that I've forgotten about.

--
Matt G|There is no Darkness in Eternity/But only Light too dim for us to see
Brainbench MVP for Linux Admin / mail: TRAP + SPAN don't belong
http://www.brainbench.com / Hire me!
-----------------------------/ http://crow202.dyndns.org/~mhgraham/resume

imotgm

unread,
Aug 10, 2004, 9:07:37 PM8/10/04
to
On Tue, 10 Aug 2004 23:40:59 +0000, Dances With Crows wrote:


> This should all work properly. Try removing the boot= line, and post
> the output of grub --version... versions older than 0.92 may have some
> weird quirks that I've forgotten about.

OP multi posted in c.o.l.setup, and thats the same thing I told him there.
Everything else looks good to me too.

--
imotgm

Douglas Mayne

unread,
Aug 11, 2004, 10:33:47 AM8/11/04
to

You have a boot partition. The files that grub sees are prior to be mounted
in the linux root tree (they are relative to the partition where they reside.)
Check your paths. You don't want to have "/boot/boot/grub/grub.conf"
when mounted.

You can access the grub shell because part of the setup succeeded, but
the link to the menu has the wrong path. Which version of grub are you
running? Some versions want menu.lst and others use grub.conf. Create
a link if one doesn't exist.

You should see something like this when you run grub:

grub> root (hd0,0)
Filesystem type is ext2fs, partition type 0x83

grub> setup (hd0)
Checking if "/boot/grub/stage1" exists... no
Checking if "/grub/stage1" exists... yes
Checking if "/grub/stage2" exists... yes
Checking if "/grub/e2fs_stage1_5" exists... yes
Running "embed /grub/e2fs_stage1_5 (hd0)"... 22 sectors are embedded.
succeeded
Running "install /grub/stage1 (hd0) (hd0)1+22 p (hd0,0)/grub/stage2
/grub/grub.conf"... succeeded
Done.


--
Seth Brundle: Computers are dumb, they only know what you tell them.
http://us.imdb.com/title/tt0091064/

Jim

unread,
Aug 11, 2004, 10:40:44 AM8/11/04
to
In article
<slrnchinfd.soo.danS...@samantha.crow202.dyndns.org>,
danSPANcesw...@usa.net says...

> I don't have a boot= line in my grub.conf . I don't even think it's a
> supported configuration option, though obviously it works if you specify
> the config file manually.
>
> > default=0
> > timeout=15
> > title Red Hat Linux (2.4.20-28.7smp)
> > root (hd0,0)
> > kernel /vmlinuz-2.4.20-28.7smp ro root=/dev/sdb5 console=ttyS0
> > initrd /initrd-2.4.20-28.7smp.img
> >
> > Why don't I get the menu (and subsequently, the autoloading of the
> > kernels)? Thanks.
>
> This should all work properly. Try removing the boot= line, and post
> the output of grub --version... versions older than 0.92 may have some
> weird quirks that I've forgotten about.

Thanks for the help. I removed the boot= line, rebooted and same issue
(I'm at the grub> shell). Grub version is 0.91 (I'm on RH 7.3, with a
2.4.20-28.7smp kernel).

Anything else to try?

Jim

Jim

unread,
Aug 11, 2004, 11:05:55 AM8/11/04
to
In article <pan.2004.08.11....@SLACKWARE-3.localnet>,
do...@SLACKWARE-3.localnet says...

> You have a boot partition. The files that grub sees are prior to be mounted
> in the linux root tree (they are relative to the partition where they reside.)
> Check your paths. You don't want to have "/boot/boot/grub/grub.conf"
> when mounted.

Thanks for the reply. I'm not sure if something is screwed up or not.
I have a /boot/grub/ directory and a /boot/boot/grub/ directory:

[root@frog root]# ls -al /boot/grub/*
-rw-r--r-- 1 root root 82 Jan 30 2004
/boot/grub/device.map
-rw-r--r-- 1 root root 993 Aug 11 10:58
/boot/grub/grub.conf
lrwxrwxrwx 1 root root 20 Aug 11 10:58
/boot/grub/menu.lst -> f
-rw-r--r-- 1 root root 33585 Apr 9 2002
/boot/grub/splash.xpm.gz
[root@frog root]# ls -al /boot/boot/grub/*
-rw-r--r-- 1 root root 45 Jul 27 17:54
/boot/boot/grub/device.p
-rw-r--r-- 1 root root 10880 Aug 10 14:50
/boot/boot/grub/e2fs_st5
-rw-r--r-- 1 root root 9808 Aug 10 14:50
/boot/boot/grub/fat_sta5
-rw-r--r-- 1 root root 8896 Aug 10 14:50
/boot/boot/grub/ffs_sta5
-rw-r--r-- 1 root root 11104 Aug 10 14:50
/boot/boot/grub/jfs_sta5
-rw-r--r-- 1 root root 9280 Aug 10 14:50
/boot/boot/grub/minix_s5
-rw-r--r-- 1 root root 12576 Aug 10 14:50
/boot/boot/grub/reiserf5
-rw-r--r-- 1 root root 512 Aug 10 14:50
/boot/boot/grub/stage1
-rw-r--r-- 1 root root 131008 Aug 10 14:50
/boot/boot/grub/stage2
-rw-r--r-- 1 root root 8544 Aug 10 14:50
/boot/boot/grub/vstafs_5
-rw-r--r-- 1 root root 12744 Aug 10 14:50
/boot/boot/grub/xfs_sta5

When I run grub, my paths are slightly different from yours:

grub> root (hd0,0)
Filesystem type is ext2fs, partition type 0x83

grub> setup (hd0)
Checking if "/boot/grub/stage1" exists... yes
Checking if "/boot/grub/stage2" exists... yes
Checking if "/boot/grub/e2fs_stage1_5" exists... yes
Running "embed /boot/grub/e2fs_stage1_5 (hd0)"... 22 sectors are
embedded.
succeeded
Running "install /boot/grub/stage1 d (hd0) (hd0)1+22 p
(hd0,0)/boot/grub/stage
2 /boot/grub/grub.conf"... succeeded
Done.

Is this my error? How do I correct? Thanks.

Jim

Douglas Mayne

unread,
Aug 11, 2004, 11:18:40 AM8/11/04
to
On Wed, 11 Aug 2004 11:05:55 -0400, Jim wrote:

> In article <pan.2004.08.11....@SLACKWARE-3.localnet>,
> do...@SLACKWARE-3.localnet says...
>> You have a boot partition. The files that grub sees are prior to be mounted
>> in the linux root tree (they are relative to the partition where they reside.)
>> Check your paths. You don't want to have "/boot/boot/grub/grub.conf"
>> when mounted.
>
> Thanks for the reply. I'm not sure if something is screwed up or not.
> I have a /boot/grub/ directory and a /boot/boot/grub/ directory:
>

<snip>


>
> When I run grub, my paths are slightly different from yours:
>
> grub> root (hd0,0)
> Filesystem type is ext2fs, partition type 0x83
>
> grub> setup (hd0)
> Checking if "/boot/grub/stage1" exists... yes
> Checking if "/boot/grub/stage2" exists... yes
> Checking if "/boot/grub/e2fs_stage1_5" exists... yes
> Running "embed /boot/grub/e2fs_stage1_5 (hd0)"... 22 sectors are
> embedded.
> succeeded
> Running "install /boot/grub/stage1 d (hd0) (hd0)1+22 p
> (hd0,0)/boot/grub/stage
> 2 /boot/grub/grub.conf"... succeeded
> Done.
>
> Is this my error? How do I correct? Thanks.
>

Yes, you want to see this line:


grub> setup (hd0)
Checking if "/boot/grub/stage1" exists... no

> Jim
>
<snip>
>
To fix it, be careful, but I recommend truncating
that directory path. How about moving out of the way:

mv /boot/boot /tmp

Then, re-run the grub shell to setup.

--
Group Captain Lionel Mandrake: Colonel Bat Guano,
if that is your real name...
http://us.imdb.com/title/tt0057012/quotes

imotgm

unread,
Aug 11, 2004, 9:06:34 PM8/11/04
to
On Wed, 11 Aug 2004 09:18:40 -0600, Douglas Mayne wrote:


> Yes, you want to see this line:
> grub> setup (hd0)
> Checking if "/boot/grub/stage1" exists... no

Pardon my butting in here, but I'm trying to follow your logic. On my
machine, with (hd0,0) unmounted, there is a link "/boot". When I
temporarily mount it on /data1, and cd to /data1;

imotgm@fatman:/data1> ls -l | grep boot
lrwxrwxrwx 1 root root 1 2003-04-28 12:09 boot -> .

Which means whether grub looks for /grub/stage1, or /boot/grub/stage1, it
will find the exact same file.

If there is no /boot link, then searching for /boot/grub/stage1 will
obviously give the results as no, but if the link is present it will give
the results as yes, as it should.

Either way, once it finds stage1, it installs that to the MBR, and however
it found it, is irrelevant to the actual boot process. Even if it looked
for /boot/boot/boot/grub/stage1, stage2 or whatever, it would find it, if
it is present in the /grub directory of the boot partition (hd0,0).

Looking in the /grub/nbgrub the first line gives the default path
/boot/grub/stage1, and is the reason for the /boot link being in the root
directory of the boot partition. The same path can be used for a boot
partition as is used for a /boot directory.

My question is simply, why are you assuming that the OP has an error, when
running the setup program, and getting what, for his set up, which
appears to be the same as mine, is a correct reading? Why would you
conclude that this would have a bearing on the OP's problem. I get the
same output as he does, and my grub works fine.

Having found all of the appropriate files, on the correct default path,
I'd be more prone to looking elsewhere for a solution. Did the OP take
your advise and check to see if the menu.lst that he is working with, is
linked to grub.conf, which is what the setup program shows it is looking
for.

Running "install /boot/grub/stage1 d (hd0) (hd0)1+22 p
(hd0,0)/boot/grub/stage
2 /boot/grub/grub.conf"... succeeded
Done.

If menu.lst is an actual file, rather than a link to grub.conf, then
grub.conf needs to be a link to menu.lst, rather than an actual file. Or
if grub.conf is an actual file, and menu.lst is an actual file, OP needs
to be working with grub.conf, as grub is not looking for menu.lst.

--
imotgm

Douglas Mayne

unread,
Aug 12, 2004, 9:37:21 AM8/12/04
to
On Thu, 12 Aug 2004 01:06:34 +0000, imotgm wrote:

> On Wed, 11 Aug 2004 09:18:40 -0600, Douglas Mayne wrote:
>
>
>> Yes, you want to see this line:
>> grub> setup (hd0)
>> Checking if "/boot/grub/stage1" exists... no
>
> Pardon my butting in here, but I'm trying to follow your logic. On my
> machine, with (hd0,0) unmounted, there is a link "/boot". When I
> temporarily mount it on /data1, and cd to /data1;
>
> imotgm@fatman:/data1> ls -l | grep boot
> lrwxrwxrwx 1 root root 1 2003-04-28 12:09 boot -> .
>
> Which means whether grub looks for /grub/stage1, or /boot/grub/stage1, it
> will find the exact same file.

Grub must look for files before the OS has loaded (because, it's job is to
load the OS.) Files will be relative to the partition where they reside.

>
> If there is no /boot link, then searching for /boot/grub/stage1 will
> obviously give the results as no, but if the link is present it will give
> the results as yes, as it should.
>
> Either way, once it finds stage1, it installs that to the MBR, and however
> it found it, is irrelevant to the actual boot process. Even if it looked
> for /boot/boot/boot/grub/stage1, stage2 or whatever, it would find it, if
> it is present in the /grub directory of the boot partition (hd0,0).

Yes, that is true for the stage files. It can be wrong for the menu. See
my notes about "install" below.

>
> Looking in the /grub/nbgrub the first line gives the default path
> /boot/grub/stage1, and is the reason for the /boot link being in the root
> directory of the boot partition. The same path can be used for a boot
> partition as is used for a /boot directory.
>
> My question is simply, why are you assuming that the OP has an error, when
> running the setup program, and getting what, for his set up, which
> appears to be the same as mine, is a correct reading? Why would you
> conclude that this would have a bearing on the OP's problem. I get the
> same output as he does, and my grub works fine.

Do you have a boot partition? Do you want me to try to diagnose why your
system works ;-) ? I am assuming the OP has an error because he is
writing in complaining of one. His path /boot/boot/grub could be a point
of confusion if nothing else. Say, he were to edit /boot/grub/grub.conf
and not see any effect upon reboot because /boot/boot/grub/grub.conf was
the actual menu- that would be confusing.

>
> Having found all of the appropriate files, on the correct default path,
> I'd be more prone to looking elsewhere for a solution. Did the OP take
> your advise and check to see if the menu.lst that he is working with, is
> linked to grub.conf, which is what the setup program shows it is looking
> for.

He hasn't posted a reply yet. A lot of people post questions and don't
seem to care if they're answered or not.

>
> Running "install /boot/grub/stage1 d (hd0) (hd0)1+22 p
> (hd0,0)/boot/grub/stage
> 2 /boot/grub/grub.conf"... succeeded
> Done.
>
> If menu.lst is an actual file, rather than a link to grub.conf, then
> grub.conf needs to be a link to menu.lst, rather than an actual file. Or
> if grub.conf is an actual file, and menu.lst is an actual file, OP needs
> to be working with grub.conf, as grub is not looking for menu.lst.
>

See part of answer inline. Part of the confusion with grub comes from the
fact that grub runs in two environments:

1. From within a mounted filesystem (to setup the loader.)
2. From the boot environment (before the filesystem is mounted.)

The original poster is complaining that grub loads to the shell only at
boot. The menu is not available, and he has to enter commands manually
to boot his system, if I understood correctly. This implies the stage
files are installed correctly, but stage2 has a bad value "patched" in
place which links to the menu. See description of install below.

grub> help install
install: install [--stage2=STAGE2_FILE] [--force-lba] STAGE1 [d] DEVICE
STAGE2 [ADDR] [p] [CONFIG_FILE] [REAL_CONFIG_FILE]
Install STAGE1 on DEVICE, and install a blocklist for loading STAGE2
as a Stage 2. If the option `d' is present, the Stage 1 will always
look for the disk where STAGE2 was installed, rather than using the
booting drive. The Stage 2 will be loaded at address ADDR, which will
be determined automatically if you don't specify it. If the option `p'
or CONFIG_FILE is present, then the first block of Stage 2 is patched
with new values of the partition and name of the configuration file
used by the true Stage 2 (for a Stage 1.5, this is the name of the
true Stage 2) at boot time. If STAGE2 is a Stage 1.5 and
REAL_CONFIG_FILE is present, then the Stage 2 CONFIG_FILE is patched
with the configuration filename REAL_CONFIG_FILE. If the option
`--force-lba' is specified, disable some sanity checks for LBA mode.
If the option `--stage2' is specified, rewrite the Stage 2 via your
OS's filesystem instead of the raw device.

--
That's our new computer. We can pinpoint any fire in town with that.
It's perfect for us, because, you know, we're the fire department.
http://us.imdb.com/title/tt0093886/quotes

Jim

unread,
Aug 12, 2004, 1:10:03 PM8/12/04
to
In article <pan.2004.08.11....@SLACKWARE-3.localnet>,
do...@SLACKWARE-3.localnet says...

> To fix it, be careful, but I recommend truncating


> that directory path. How about moving out of the way:
>
> mv /boot/boot /tmp
>
> Then, re-run the grub shell to setup.
>

Doug

Thanks for the help. This fixed it. I discovered the "original" source
of the problem. When I ran grub-install the first time, I specified:

grub-install --root-directory=/boot '(hd0,0)'

For some reason I thought I needed to specify the --root-directory
switch. After moving /boot/boot out of the way, I reran without the --
root switch and everything worked correctly.

Thanks for your assistance.

Jim

imotgm

unread,
Aug 13, 2004, 4:40:56 AM8/13/04
to
On Thu, 12 Aug 2004 07:37:21 -0600, Douglas Mayne wrote:


>> Pardon my butting in here, but I'm trying to follow your logic. On my
>> machine, with (hd0,0) unmounted, there is a link "/boot". When I
>> temporarily mount it on /data1, and cd to /data1;
>>
>> imotgm@fatman:/data1> ls -l | grep boot
>> lrwxrwxrwx 1 root root 1 2003-04-28 12:09 boot -> .
>>
>> Which means whether grub looks for /grub/stage1, or /boot/grub/stage1, it
>> will find the exact same file.

> Do you have a boot partition?

Yes, and you seem to have missed that, when I mentioned I had it
unmounted, in the first paragraph above.

No problem, as your post showed up at the same time as the OP's reply,
that he had it working, and discovered he had issued the wrong command,
when installing. This caused me to reread the whole thread, and caught the
fact that his second post showed two "ls -al" commands. I missed that, on
first read, as I was looking at the files found, and permissions. If he
had put a blank line before the second command, I would have realized that
he had a real directory /boot on his partition, rather than the /boot link
that exists on mine.

> Do you want me to try to diagnose why your system works ;-) ?

That line had me chuckling through the rest of your reply. ;-D

No, I know why mine works, it's installed properly; but thanks for the
offer. :-)

> He hasn't posted a reply yet. A lot of people post questions and don't
> seem to care if they're answered or not.

Well, I wanted an answer, got one that left me confused, until I caught
the real /boot directory, mentioned above, and then it all became clear.

All of what you posted, is stuff I know, but couldn't see how it fit the
situation, when trying to reproduce his problem on my system. I now see
why, in his case, it was necessary to get that real /boot directory out of
his search path.

I really appreciate your response, as it did lead, in a slightly round
about manner, to my fully understanding the OP's situation. This is just
to say thank you for that, and to let you know that I did, in fact, read
it, and found it very helpful. I too, have noticed a lot of posters never
acknowledge that they have even read, yet alone found useful, replies to
their questions. Very rude, at best.

Thanks, again. ;-)

P.S. You could have saved a lot of writing, if you had just said, "OP's
/boot/boot is a real directory, not a link, as in your case." ;-D

--
imotgm

Douglas Mayne

unread,
Aug 13, 2004, 11:36:18 AM8/13/04
to
On Fri, 13 Aug 2004 08:40:56 +0000, imotgm wrote:

> On Thu, 12 Aug 2004 07:37:21 -0600, Douglas Mayne wrote:
>
>

<snip>


>
> Well, I wanted an answer, got one that left me confused, until I caught
> the real /boot directory, mentioned above, and then it all became clear.
>
> All of what you posted, is stuff I know, but couldn't see how it fit the
> situation, when trying to reproduce his problem on my system. I now see
> why, in his case, it was necessary to get that real /boot directory out of
> his search path.
>
> I really appreciate your response, as it did lead, in a slightly round
> about manner, to my fully understanding the OP's situation. This is just
> to say thank you for that, and to let you know that I did, in fact, read
> it, and found it very helpful. I too, have noticed a lot of posters never
> acknowledge that they have even read, yet alone found useful, replies to
> their questions. Very rude, at best.
>
> Thanks, again. ;-)
>
> P.S. You could have saved a lot of writing, if you had just said, "OP's
> /boot/boot is a real directory, not a link, as in your case." ;-D
>

I think the OP must have had both a link (mount point for partition)
and a directory (/boot) on that partition, leading to the path /boot/boot.

Keep up the good work! I have only been reading newsgroups for a short
time and have learned a lot so far. I have been recommending people
switch to gnu/linux, and use google and newsgroups for support. This
may be better than paid technical support:
http://slashdot.org/articles/01/04/27/1715203.shtml

--
But they said the Commodore would withstand anything!
http://us.imdb.com/title/tt0097257/quotes

name

unread,
Aug 13, 2004, 7:28:02 PM8/13/04
to

Read this thread with interest. I've been using Grub for years, mostly with
Mandrake, but also with Slackware and Debian. The Mandrake partition
controlled the boot loader. In the past, in order to change the controlling
installation, I used 'grub-install'. For instance, if I was moving control
to a newer Mandrake installation on /dev/hda11, I would type "grub-install
'(hd0,10)'" (trying to cite a command using quotes to delineate it sucks
when the command ends with a quote!).

The last time I switched command, this didn't work, and dim bulb here didn't
think to log the new command that did work. So....

After reading man, info, and website material on Grub, I'm still confused.
This is one command I want to get right the first time, because redoing it
after discovering that it not only didn't work but screwed up the MBR (set
my system afire, and make demons issue from my nose... nah, that last is
the result of UB in C. If you don't know the reference, don't ask...lol!!!)

Anyway, the solution cited in the post to which I'm following up doesn't
work for me. As I recall, what I did was within the grub shell itself, but
I can't figure out what that must have been.

The partition to which I'm switching control has Grub installed in the usual
place: /boot/grub. I've got a menu.lst ready to slip into place, and I will
be doing the deed from within that installation (Mdk-10.0).

What have I forgotten, or what am I missing here?

Thanks for reading!
--
Email is wtallman at olypen dot com

imotgm

unread,
Aug 14, 2004, 2:06:51 AM8/14/04
to
On Fri, 13 Aug 2004 23:28:02 +0000, name wrote:


> The partition to which I'm switching control has Grub installed in the usual
> place: /boot/grub. I've got a menu.lst ready to slip into place, and I will
> be doing the deed from within that installation (Mdk-10.0).

If you have a menu.lst ready to slip into place, do so, and then Install
grub. That's pretty straight forward; what, exactly, is your problem?

If you are regularly running more than one Linux distro, you should really
have a boot partition, where grub, and all your kernels reside. I've had
the same grub installation since Suse 8.0 was new, and have never had a
need to reinstall it, even though Suse 8.0 is no longer on the machine. I
also do not mount the partition on any of the 9 distros I'm currently
running, to keep it safe from accidental over-writes.

Grub does not need to be reinstalled, to the MBR, each time you add a new
distro. You only need to add a new stanza to menu.lst to add it to the
grub menu you see at start up. If the /grub directory is on a boot
partition, it is independent from any individual distro.

--
imotgm

name

unread,
Aug 14, 2004, 2:50:26 AM8/14/04
to
On 2004-08-14, imotgm <imotgm...@invalid-yahoo.com> wrote:
> On Fri, 13 Aug 2004 23:28:02 +0000, name wrote:
>
>
>> The partition to which I'm switching control has Grub installed in the usual
>> place: /boot/grub. I've got a menu.lst ready to slip into place, and I will
>> be doing the deed from within that installation (Mdk-10.0).
>
> If you have a menu.lst ready to slip into place, do so, and then Install
> grub. That's pretty straight forward; what, exactly, is your problem?

How to do it. "grub-install '(hdx,y)'" doesn't work. Used to but something
changed, and I don't recall the new command. I don't remember whether or
not I used the Grub shell

> If you are regularly running more than one Linux distro, you should really
> have a boot partition, where grub, and all your kernels reside. I've had
> the same grub installation since Suse 8.0 was new, and have never had a
> need to reinstall it, even though Suse 8.0 is no longer on the machine. I
> also do not mount the partition on any of the 9 distros I'm currently
> running, to keep it safe from accidental over-writes.

Hmmmm.... food for thought! My immediate reaction is that I should have
done that when I was really doing a lot of different distros, although not
that many! At the moment, I'm moving more towards Slackware as the distro
of choice, but haven't yet successfully addressed some of the hand
configuration automagically done in Mandrake. Fact is, I get rid of distros
and use the partition for data and archives and such.

But I shall remember this. Sounds like an excellent idea, and would
probably work even for distros on different drives.

> Grub does not need to be reinstalled, to the MBR, each time you add a new
> distro. You only need to add a new stanza to menu.lst to add it to the
> grub menu you see at start up. If the /grub directory is on a boot
> partition, it is independent from any individual distro.

Yep, I know that, but I want it to point to a different partition now. Used
to be trivial to do, and probably still is. I've just forgotten how...

Thanks for responding!

imotgm

unread,
Aug 14, 2004, 9:03:41 AM8/14/04
to
On Sat, 14 Aug 2004 06:50:26 +0000, name wrote:

> On 2004-08-14, imotgm <imotgm...@invalid-yahoo.com> wrote:
>> On Fri, 13 Aug 2004 23:28:02 +0000, name wrote:
>>
>>
>>> The partition to which I'm switching control has Grub installed in the usual
>>> place: /boot/grub. I've got a menu.lst ready to slip into place, and I will
>>> be doing the deed from within that installation (Mdk-10.0).
>>
>> If you have a menu.lst ready to slip into place, do so, and then Install
>> grub. That's pretty straight forward; what, exactly, is your problem?
>
> How to do it. "grub-install '(hdx,y)'" doesn't work. Used to but something
> changed, and I don't recall the new command. I don't remember whether or
> not I used the Grub shell

As root; grub-install /dev/hda

If you just want it done and over.

or;

In /boot/grub, where you will copy your revised menu.lst, is a shell
script, install.sh. As root, open it with your favorite editor, and make
sure it is set to install to (hd0), and then run it.

or;

If you prefer GUI install, open MCC -> Boot -> Boot loader and for
"Bootloader to use" pick grub from the dropdown menu, and for "Boot
device" /dev/hda, and click next

> But I shall remember this. Sounds like an excellent idea, and would
> probably work even for distros on different drives.

I boot distros on hda, hdc, hde, and hdg. All directly, no chainloading,
except for Windows.

>
>> Grub does not need to be reinstalled, to the MBR, each time you add a new
>> distro. You only need to add a new stanza to menu.lst to add it to the
>> grub menu you see at start up. If the /grub directory is on a boot
>> partition, it is independent from any individual distro.
>
> Yep, I know that, but I want it to point to a different partition now. Used
> to be trivial to do, and probably still is. I've just forgotten how...

See above. ;-D

For study, info grub
For easy navigation of info, urpmi pinfo

--
imotgm

name

unread,
Aug 14, 2004, 11:06:12 PM8/14/04
to
On 2004-08-14, imotgm <imotgm...@invalid-yahoo.com> wrote:

<snip>


>> How to do it. "grub-install '(hdx,y)'" doesn't work. Used to but something
>> changed, and I don't recall the new command. I don't remember whether or
>> not I used the Grub shell
>
> As root; grub-install /dev/hda
>
> If you just want it done and over.

<snip>

Okay, thanks! I presume that grub is now smart enough to figure out which
partition has the grub installation and the menu, etc? In other words, I
don't have to type "grub-install /dev/hda1" if I want it to point to
/dev/hda11? Wish the docs were more specific abou this, and that the docs
on the site agreed with the man and info files, and....

Anyway, thanks again!

0 new messages