Help with GRUB most urgently needed.
Aug. 1st, 2005 12:08 am(Warning: not only geeky, but geeky in a horribly Linux way. I'm extremely happy with Ubuntu as long as I can forget there's Linux at the bottom of it, and it just reminded me.)
I managed to cleverly trash GRUB by editing /boot/grub/menu.lst directly by hand to boot Windows 2000 from /dev/hda5. Bad move — on reboot, stage 2 came back with the infamous Error 17 (can't see a file system).
I went in with the Ubuntu Live CD and mounted /dev/hda1 to /mnt just fine — so the file system is there. Couldn't work out from the docs how to get it to rewrite the bootstrap so it would start up properly.
Eventually I thought, "OK, it should be possible to get it to boot into the Windows partition if I reinstall the NT boot." Put in the Windows 2000 CD, went to recovery console, did fixmbr, rebooted, it didn't work, did fixboot, rebooted, it didn't work. You will note that by this stage I was trying things more or less at random.
I could "fix" it easily enough by reinstalling from scratch (and this time getting the dual-boot right) — I'd only lose a day's effort — but I'd rather get myself out of this one if at all possible. What have I trashed, is it recoverable and how do I get back to a booting system? For bonus points: how do I get it to recognise the Windows 2000 partition as bootable? You will earn so many *pint*s for supplying the winning answer, or even approximations.
Update: Solved! The partition type was wrong. *pint* to
dennyd.
(no subject)
Date: 2005-07-31 11:28 pm (UTC)grub does not need to be reinserted into the MBR every time your config for it changes(unlike lilo). My guess is you turned off initrd support. I am guessing hda1 is ext3? I don't know about Ubuntu but standard debian lkernels have ext3 as a module, which would necessitate initrd.
Try using apt to get a newer or older kernel, then compare the boot stanza it inserts tou the one for your regular linux kernel.
(no subject)
Date: 2005-07-31 11:49 pm (UTC)(no subject)
Date: 2005-08-01 12:04 am (UTC)(no subject)
Date: 2005-08-01 05:39 am (UTC)Editing the menu.lst file does not require running any other command afterward.
I would just boot the live CD, mount the old filesystems as "/mnt" (don't forget your old /boot if you have it) and run "grub-install --recheck --root-directory=/mnt/boot /dev/hda". This should install a new MBR and point it to the stage1 and 2 on /mnt/boot/grub/.
To recreate the menu.lst file, boot into the system (either directly or using chroot) and run update-grub.
To boot my XP on /dev/hda1 I use:
The "makeactive" should make the XP mbr happy as it won't boot from a non-active partition.
(no subject)
Date: 2005-08-01 08:07 am (UTC)I edited menu.lst, rebooted, it came back with error 17, I went in and changed it back from the live CD, rebooted, it came back with error 17 ... I assume the command line only comes up if stage 2 works.
(no subject)
Date: 2005-08-01 06:11 am (UTC)So this little lot boots from the first partition on the second harddrive
title Ubuntu, kernel 2.6.10-5-686
root (hd1,0)
kernel /boot/vmlinuz-2.6.10-5-686 root=/dev/hdc1 ro quiet splash
initrd /boot/initrd.img-2.6.10-5-686
savedefault
boot
And these lines boot W2K from the first partition in the first hard drive.
# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/hda1
title Windows NT/2000/XP
root (hd0,0)
savedefault
makeactive
chainloader +1
(no subject)
Date: 2005-08-01 09:19 am (UTC)As someone else has mentioned, grub doesn't speak /dev/hdXN - you'll be needing to RTFM to figure out the obscure hd(0,0) gibberish... I think it's something like /dev/hdb4 == hd(1,3) for instance, but the docs will tell you for sure.
(no subject)
Date: 2005-08-01 11:44 am (UTC)(no subject)
Date: 2005-08-01 11:15 pm (UTC)# mount /dev/hda1 /mnt
# chroot /mnt
# grub-install /dev/hda
The file /boot/grub/stage1 not read correctly.
Um ... now what?
(no subject)
Date: 2005-08-01 11:43 pm (UTC)Does this help?
http://lists.linuxcoding.com/rhl/2005/msg07520.html
(no subject)
Date: 2005-08-01 11:58 pm (UTC)And this:
Not sure if either is relevant to your woes... it seems grub throws this error under a helpful variety of circumstances.
(no subject)
Date: 2005-08-02 12:16 am (UTC)*pint* to the *pint* to the *pint*pint*pint*
(no subject)
Date: 2005-08-02 08:19 am (UTC)PS: Amoeba? ?! indeed.