[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Request for help debugging this grub problem
From: |
Yedidyah Bar-David |
Subject: |
Re: Request for help debugging this grub problem |
Date: |
Sun, 28 Sep 2003 00:25:43 +0300 |
User-agent: |
Mutt/1.4i |
Hello Jon,
Your problem isn't with grub, but with ntldr. Can you please post your
boot.ini? I guess the relevant line is something like this:
c:\somefile="GRUB"
where somefile is a copy of the first sector of /dev/hda3.
I really can't imagine this happening without your intervention, so
either you forgot you did it or someone did it for you.
How to solve it?
1. The ugly way - copy again your first sector to a file. This is
ugly because if your NT is on NTFS you will have to copy this
sector to a floppy (or some other FAT partition, network etc.),
reboot to NT, and copy it back over somefile.
2. The good way - simply install grub on /dev/hda (the MBR) and add
an entry for NT
(something like
title Windows XP
rootnoverify (hd0,0)
chainloader +1
boot).
--
Didi
On Sat, Sep 27, 2003 at 11:48:58PM +1000, Jon Seymour wrote:
> I have had grub installed on my RedHat 8 system for sometime now. It had
> been working fine.
>
> Just recently, I needed to compile a later kernel (2.4.21) to take
> advantage of some additional functionality.
>
> make install on the kernel updated my grub configuration, but I can no
> longer boot from the hard disk.
>
> The symptom is a console with the following message:
>
> GRUB<space>
>
> To explain my setup:
>
> * the MBR of hd0 boots into Windows XP on /dev/hda1 [ kept around so
> that I can use partition magic ]
> * boot.ini of Windows XP has been configured with one item for
> Windows XP and one for /dev/hda3
> * the Linux root file system is on /dev/hda5 (hd0,4)
> * the boot file system is on /dev/hda3 (hd0,2) and is mounted over
> /boot when /dev/hda5 is the root fs.
> * /dev/hda3 and /dev/hda5 are ext2 partitions
>
> I tried re-installing grub with:
>
> grub-install /dev/hda3
>
> I also tried:
>
> grub-install --root-directory=/boot /dev/hda3
>
> but neither option helped.
>
> So, I booted off a linux recovery disk and tried installing grub on a
> new floppy disk with:
>
> grub-install /dev/fd0
>
> I copied grub.conf from (hd0,2)/grub/grub.conf on (fd0)/boot/grub.
>
> When I boot from this floppy disk, this works as expected - a grub menu
> appears and I can select the OS image I want to boot from the grub menu.
>
> Having tried everything I could think off to get the harddisk booting, I
> resorted to using xxd to edit the stage1 file in /usr/share/grub so that
> byte0x17c was 'g' rather than 'G'. This is the first letter of the first
> message that "GRUB" writes to the console when the boot record is
> executed. I then did a grub-install /dev/fd0 and confirmed that the boot
> message was gRUB rather than GRUB. However, if then I did a grub-install
> /dev/hda3 and then tried to boot the boot message was GRUB rather than
> the expected "gRUB". This seems to indicate to me that the stage1 file
> it is executing isn't the one that gets installed by grub-install
> (otherwise the message should read gRUB).
>
> I am not sure if it is relevant, but here is a copy of the partition
> table (captured with sfdisk). fdisk reports that the partition table is
> "out of order". I haven't tried an reordering the partition table yet
> because I am afraid of the consequences of doing so.
>
> Disk /dev/hda: 4998 cylinders, 255 heads, 63 sectors/track
> Units = cylinders of 8225280 bytes, blocks of 1024 bytes, counting from 0
>
> Device Boot Start End #cyls #blocks Id System
> /dev/hda1 * 0+ 764 765- 6144831 7 HPFS/NTFS
> /dev/hda2 4735 4997 263 2112547+ 1c Hidden Win95 FAT32
> (LBA)
> /dev/hda3 765 777 13 104422+ 83 Linux
> /dev/hda4 778 4734 3957 31784602+ f Win95 Ext'd (LBA)
> /dev/hda5 778+ 4591 3814- 30635923+ 83 Linux
> /dev/hda6 4592+ 4721 130- 1044193+ 82 Linux swap
> start: (c,h,s) expected (1023,254,63) found (1023,1,1)
> /dev/hda7 4722+ 4734 13- 104391 b Win95 FAT32
> start: (c,h,s) expected (1023,254,63) found (1023,1,1)
>
> For the record, here is my grub.conf file located in
> /boot/grub/grub.conf (hd0,2)/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,2)
> # kernel /vmlinuz-version ro root=/dev/hda5
> # initrd /initrd-version.img
> # boot=/dev/hda3
> default=0
> timeout=10
> splashimage=(hd0,2)/grub/splash.xpm.gz
> title Red Hat Linux (2.4.18-14)
> root (hd0,2)
> kernel /vmlinuz-2.4.18-14 ro root=LABEL=/ hdc=ide-scsi
> initrd /initrd-2.4.18-14.img
> title DOS
> rootnoverify (hd0,0)
> chainloader +1
>
>
> Any thoughts about why grub has started misbehaving for me?
>
> jon.
>
>
>
> _______________________________________________
> Bug-grub mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/bug-grub