LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Fedora (https://www.linuxquestions.org/questions/fedora-35/)
-   -   grub doesn't show boot menu, just goes directly into Linux ? (https://www.linuxquestions.org/questions/fedora-35/grub-doesn%27t-show-boot-menu-just-goes-directly-into-linux-825913/)

trien27 08-12-2010 08:29 PM

grub doesn't show boot menu, just goes directly into Linux ?
 
Fedora 13 = Primary Master drive
Windows XP = Secondary Master drive

I installed Fedora 13 from a cd.
Here's my fdisk:
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/dm-0 doesn't contain a valid partition table

Disk /dev/dm-1: 1073 MB, 1073741824 bytes
255 heads, 63 sectors/track, 130 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/dm-1 doesn't contain a valid partition table

Disk /dev/dm-2: 28.2 GB, 28152168448 bytes
255 heads, 63 sectors/track, 3422 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/dm-2 doesn't contain a valid partition table

Here's my /boot/grub/grub.conf:
# 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/mapper/vg_bryan-lv_root
# initrd /initrd-[generic-]version.img
#boot=/dev/sda
default=0
timeout=0
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Fedora (2.6.33.6-147.2.4.fc13.i686)
root (hd0,0)
kernel /vmlinuz-2.6.33.6-147.2.4.fc13.i686 ro root=/dev/mapper/vg_bryan-lv_root rd_LVM_LV=vg_bryan/lv_root rd_LVM_LV=vg_bryan/lv_swap rd_NO_LUKS rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet
initrd /initramfs-2.6.33.6-147.2.4.fc13.i686.img
title Windows XP
rootnoverify (hd0,1)

my grub/menu.lst is the same as /boot/grub.grub.conf

Thanks.

brucehinrichs 08-12-2010 09:10 PM

Change the timeout value and comment out the hiddenmenu line:

Code:

# 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/mapper/vg_bryan-lv_root
# initrd /initrd-[generic-]version.img
#boot=/dev/sda
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
#hiddenmenu
title Fedora (2.6.33.6-147.2.4.fc13.i686)
root (hd0,0)
kernel /vmlinuz-2.6.33.6-147.2.4.fc13.i686 ro root=/dev/mapper/vg_bryan-lv_root rd_LVM_LV=vg_bryan/lv_root rd_LVM_LV=vg_bryan/lv_swap rd_NO_LUKS rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet
initrd /initramfs-2.6.33.6-147.2.4.fc13.i686.img
title Windows XP
rootnoverify (hd0,1)

See if that does it. :)

yancek 08-12-2010 09:51 PM

Agree with brucehinrichs and the menu.lst file you see is a link to the grub.conf file

trien27 08-15-2010 01:07 PM

Thanks, Bruce.
Changing the timeout and commenting out the hiddenmenu works.

Last time I got the grub menu, but when I went to Windows XP, there's an Error 13. Hope I don't get it now.

I will try to get into Windows XP now and see what happens.

trien27 08-15-2010 01:15 PM

New problem:
Using Grub menu doesn't boot into Windows XP, clicking on Windows XP just gets a blank screen, then gets me back to the Grub dualboot menu, not Windows XP? Using F12 at the splash screen and selecting Primary Slave Drive does work and boots into Windows XP. Should I use mapping/remapping?

Thanks.

DrLove73 08-15-2010 03:48 PM

You are missing
Code:

chainloader +1
at the bottom of the file, below
Quote:

title Windows XP
rootnoverify (hd0,1)

trien27 08-15-2010 09:49 PM

Now I get the grub menu with WinXP, but when I click and tried to load it, there's an Error 13: Invalid or unsupported executable format. I have no idea what else could be wrong. I already added the line

chainloader +1

but still get this problem.

Thanks.

DrLove73 08-16-2010 03:35 AM

UuuuPSsss, I missed your XP is on the slave drive (top of the first post). In that case you have to use
Quote:

rootnoverify (hd1,0)
or maybe
Quote:

rootnoverify (hd1,1)
(I do not use dual boot).

If this does not help. thy adding from this:

Quote:

title Windows XP
map (hd0,0) (hd1,0)
map (hd1,0) (hd0,0)
rootnoverify (hd1,0)
makeactive
chainloader +1

or

title Windows XP
root (hd1,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1

trien27 08-23-2010 08:55 PM

Tried this:
title Windows XP
map (hd0,0) (hd1,0)
map (hd1,0) (hd0,0)
rootnoverify (hd1,0)
makeactive
chainloader +1

but I get Error 21: Selected disk does not exist.

I'll try:
title Windows XP
root (hd1,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1

later and see what happens.

trien27 08-25-2010 06:43 PM

I tried:
title Windows XP
root (hd1,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1

And now:
I get Error 21: The selected hard drive does not exist[Windows XP hard drive: Primary Slave drive],
plus
I get all three OSes selections: old version of Fedora, new version of Fedora & Windows XP.

DrLove73 08-26-2010 10:28 AM

What about clean code like this:
Code:

title Windows XP
rootnoverify (hd1,0)
chainloader +1

or
Code:

title Windows XP
rootnoverify (hd1,0)
makeactive
chainloader +1

maybe those swaps do something to it.

One other thing crossed my mind. Take a look at /boot/grub/device.map file. I believe you need one extra row for "hd1". Since you added HDD later, grub might not have it in device map file and even my previos examples might work out of the box after you fix device.map file.

trien27 09-06-2010 04:54 PM

tried the rest of the posts, but none worked: Everything says "Error 21: The selected hard drive does not exist"

Larry Webb 09-06-2010 08:12 PM

Sorry did not see it was marked solved.

trien27 09-07-2010 05:57 AM

I initially thought the problem was solved. I kind of did things too quickly. It still is NOT solved.

Larry Webb 09-07-2010 06:25 AM

I have read the posts and I am confused. In fedora from terminal as root run command fdisk -l and post the results. Your original grub menu has XP on the second partition of the primary drive but above you say it is on slave.

DrLove73 09-07-2010 12:26 PM

Quote:

Originally Posted by DrLove73 (Post 4078594)
Take a look at /boot/grub/device.map file. I believe you need one extra row for "hd1". Since you added HDD later, grub might not have it in device map file and even my previous examples might work out of the box after you fix device.map file.

...

trien27 09-08-2010 08:49 PM

"Your original grub menu has XP on the second partition of the primary drive but above you say it is on slave."

Please show me where I have said that? I have never said "it is on slave". I have XP & Fedora each on their own HARD DRIVES. So how can they be on partitions?! I said XP is on the PRIMARY SLAVE DRIVE. I never said anything about partitions. Fedora 13 is on PRIMARY MASTER DRIVE.

I haven't a clue where you got "partitions" from.

I think that you're thinking "dualboot" = partitions on one hard drive. That's what it was on most systems. I'm creating my own thing: I used to have dualboot on partitions on one hard drive. What happened? The Windows OS died, but the Linux partition is alive and kicking. As I upgraded from Fedora 12 to 13, I got rid of the partitions and used the whole hard drive. Then it just happens that my other Windows hard drive recently died, so I got a new hard drive for Windows. But wired it so that Linux is in the MBR, meaning it's the first partition or hard drive / volume [Primary Master Drive [C: or "C drive" in Windows language] or /sda in UNIX/Linux language] detected when the computer starts.

trien27 09-08-2010 08:56 PM

"I have read the posts and I am confused."
That's not MY fault. I just have a unique problem you probably never experienced.

"In fedora from terminal as root run command fdisk -l and post the results."
Uh... I believe I've posted the results of fdisk -l in my initial post.

colorpurple21859 09-08-2010 09:06 PM

I think the entry should be in this order. I've had trouble in the past with the makeactive line and sometimes had to remove it.
Quote:

rootnoverify (hd1,0)
map (hd1) (hd0)
map (hd0) (hd1)
makeactive
chainloader +1
I also think if your
Quote:

/boot/grub/device.map file
is incorrect that will cause problems too.

trien27 09-27-2010 07:17 PM

Today with multiple errors on the screen via the Startup Menu, I suddenly could use the grub menu with Windows XP [This is what I'm using now]. I haven't been able to use it for the past few weeks. Other times, it will show Error 21.

DrLove73 09-28-2010 05:12 AM

Error 21 means that grub is unable to find the disk entered in config file. It was either wrongly written or it BIOS was not able to see it (like unplugged USB FLASH disk or similar).

trien27 10-11-2010 11:14 AM

I think this is the problem:
Windows BIOS & MBR. When I can see "Secondary Master Drive[Windows XP]" in Startup Menu via BIOS, then I can get into Windows XP with Grub menu in Linux.

I think the following 2 points are useful:
1. When I used Windows XP AFTER Linux, I CAN'T go into Windows XP with Grub menu.
2. When I used Windows XP BEFORE Linux, I CAN go into Windows XP with Grub menu.

This is so WEIRD!!! Otherwise, it will show Error 21 when going into Windows XP via Grub menu.

Can someone confirm this? If it's confirmed then I will make this thread as SOLVED. Thanks.

yancek 10-11-2010 02:25 PM

Try commenting out the savedefault line in your grub.conf file.

#savedefault

trien27 10-11-2010 03:35 PM

"Try commenting out the savedefault line in your grub.conf file."

I have no savedefault line to comment out. There is no savedefault line in my grub.conf file.

Larry Webb 10-11-2010 08:27 PM

Quote:

Originally Posted by trien27 (Post 4124026)
I think this is the problem:
Windows BIOS & MBR. When I can see "Secondary Master Drive[Windows XP]" in Startup Menu via BIOS, then I can get into Windows XP with Grub menu in Linux.

I think the following 2 points are useful:
1. When I used Windows XP AFTER Linux, I CAN'T go into Windows XP with Grub menu.
2. When I used Windows XP BEFORE Linux, I CAN go into Windows XP with Grub menu.

This is so WEIRD!!! Otherwise, it will show Error 21 when going into Windows XP via Grub menu.

Can someone confirm this? If it's confirmed then I will make this thread as SOLVED. Thanks.

Are you talking about swapping the bios order of the way hds boot when you refer to XP after linux and XP before linux?

trien27 10-13-2010 10:19 PM

Yes

Larry Webb 10-14-2010 05:50 AM

In order to get accurate help you will need to quit changing the bios hd boot order. It gets confusing and can make you think you are getting bad advice. When you give an error code stay with that boot order till it works. You can not change bios boot order and expect a boot loader to work.

trien27 10-14-2010 09:55 PM

Sorry, Larry.
I have misunderstood you. I just read you reply. I'm comparing the two hard drives that I have & what I see in grub & Windows BIOS Startup Menu. What I mean is:

1) If and only if I had used Windows via Startup Menu anytime prior to using Linux I will NOT see error message 21, when I go into Windows via grub menu later on.

2) But if I use Linux first and later I use Windows and still later on the same day go back into Linux, I will see Error 21 instead of going into Windows XP via grub menu successfully.

What I meant was I must use Windows before I use Linux in order to get into Windows XP successfully [Either via grub menu or BIOS Startup Menu]. If I do the opposite and use Linux [either via BIOS Startup Menu or grub menu] before Windows there plenty of chances I could run into problems with the computer and have to take plenty of time to solve these problems.


All times are GMT -5. The time now is 02:49 PM.