| Forum Home | ||||
| Press F1 | ||||
| Thread ID: 41724 | 2004-01-20 10:08:00 | Messed up Grub - won't boot Windows | John H (8) | Press F1 |
| Post ID | Timestamp | Content | User | ||
| 208689 | 2004-01-20 10:08:00 | Hi - hope you can help. I am running Fedora RedHat on one partition, and WinXP on the other. All working fine until today. I edited grub.conf and now it will not boot into Windows. After Grub starts, it shows both Fedora and DOS, and DOS is highlighted as the default OS to boot into unless I intervene within 10secs. It says it is booting into DOS, but Fedora starts up instead. I am sure I have accidentally removed something from grub.conf - I am using a laptop with a touchpad that sometimes acts unpredictably as a sticky device and before you notice it you have selected and cut a section of a document. Could one of the Linux experts tell me what is wrong here: # grub.conf generated by anaconda # # Note that you do not have to rerun grub after making changes to this file # NOTICE: You do not have a /boot partition. This means that # all kernel and initrd paths are relative to /, eg. # root (hd0,5) # kernel /boot/vmlinuz-version ro root=/dev/hda6 # initrd /boot/initrd-version.img #boot=/dev/hda default=1 timeout=10 splashimage=(hd0,5)/boot/grub/splash.xpm.gz title Fedora Core (2.4.22-1.2149.nptl) root (hd0,5) kernel /boot/vmlinuz-2.4.22-1.2149.nptl ro root=LABEL=/ hdc=ide-scsi rhgb initrd /boot/initrd-2.4.22-1.2149.nptl.img title DOS rootnoverify (hd0,0) chainloader +1 #title Fedora Core (2.4.22-1.2140.nptl) root (hd0,5) kernel /boot/vmlinuz-2.4.22-1.2140.nptl ro root=LABEL=/ hdc=ide-scsi rhgb initrd /boot/initrd-2.4.22-1.2140.nptl.img #title Fedora Core (2.4.22-1.2138.nptl) root (hd0,5) kernel /boot/vmlinuz-2.4.22-1.2138.nptl ro root=LABEL=/ hdc=ide-scsi rhgb initrd /boot/initrd-2.4.22-1.2138.nptl.img #title Fedora Core (2.4.22-1.2135.nptl) root (hd0,5) kernel /boot/vmlinuz-2.4.22-1.2135.nptl ro root=LABEL=/ hdc=ide-scsi rhgb initrd /boot/initrd-2.4.22-1.2135.nptl.img #title Fedora Core (2.4.22-1.2115.nptl) root (hd0,5) kernel /boot/vmlinuz-2.4.22-1.2115.nptl ro root=LABEL=/ hdc=ide-scsi rhgb initrd /boot/initrd-2.4.22-1.2115.nptl.img Thanks |
John H (8) | ||
| 208690 | 2004-01-20 10:41:00 | > title DOS > rootnoverify (hd0,0) > chainloader +1 How about this: # Boot Windows XP title=Windows XP root (hd0,0) chainloader (hd0,0)+1 |
Chilling_Silently (228) | ||
| 208691 | 2004-01-20 10:44:00 | Oh - BTW - It'd be safe to put a # in the first line of each of the old kernels so they dont show, chances are you'll never boot them again ;-) Just leave your 2.4.24-1 kernel and Windows and you should be good. If worst comes to worst and you MAJORLY stuff up and cant boot Linux, you can always use Knoppix or another Live Distro to boot and edit your grub.conf file :-) Cheers Chill. |
Chilling_Silently (228) | ||
| 208692 | 2004-01-20 11:17:00 | If it does bugger totally up go to windows recovery console and type fixmbr and then it will fix the boot record and load windows fine. Then just use your fedora boot floppy and redo grub! |
hamstar (4) | ||
| 208693 | 2004-01-20 12:02:00 | I would recommend fixing Grub within Linux before using the fixmbr mentioned above. I'm not in Fedora at the moment but I am sure there is a control panel type appellet that will do it. |
mikebartnz (21) | ||
| 208694 | 2004-01-20 20:37:00 | Hi guys Boy, Linux experts work late! I gave up and went to bed after my post... Thanks for all your suggestions. I did what Chill suggested in his first post, and that has recovered the options to boot into Windows XP or Fedora. And now the boot screen shows Windows XP instead of DOS, which is what was in the title from installation. I always thought DOS looked dopy, so thanks also for the little bonus Chill. mikebartnz - Thanks - I checked all of the control applets, and there is only one that seems to refer to boot, and that is Kickstart, which as far as I can see only gives you the options to reinstall or upgrade the installation, or to change over from Grub to LILO (I was interested to see that there, as someone who responded to another Linux thread said that Fedora had dropped support for LILO). I could not find one that reconfigured Grub options. I am now nervous about messing with grub.conf again (!), but could one of you please tell me how you change the default OS to boot from? |
John H (8) | ||
| 208695 | 2004-01-20 20:44:00 | Thanks again Chill. That (i.e. #) works, so only Windows XP and the latest Fedora kernel show at boot. In an earlier thread, you said something about that - I think you said I could "uncomment" the old kernels in grub.conf, but I was too embarassed to ask you what that meant. I later noticed that in these files, anything that is explanatory has # in front of it, so I guess that is what is meant by "uncomment" (if I remember your term correctly). Presumably the OS ignores anything with # in front. I must try to get a text on Linux so I understand more about the language... |
John H (8) | ||
| 208696 | 2004-01-20 21:58:00 | Right on, Usually its a # or a ; You've just got to think in Grub speak for a bit here... Everything starts at 0. Want to boot the first entry? Boot 0 by default Want to boo the second entry? Boot 1 by default default=1 timeout=10 That's what you're after to change :-) So if you rarely boot WinXP, set Linux to be the default with a timeout of, say, 3... ;-) And Vice versa.. Im pretty sure that in KDE there's an applet in the Control Center that allows modification to Lilo, but not Grub, and Lilo certainly doesnt seem as user-friendly as Grub IMO (Ive done many installs of Grub, only one failing being CC's.... Never managed to get Lilo going). It always pays to make a backup copy of your .conf files before editing them. That way if you screw up you can restore them without a care! cp /etc/grub/grub.conf /etc/grub/grub.conf.backup Works a charm (Fedora keep grub in /etc/ dont they?) ;-) Cheers Chill. |
Chilling_Silently (228) | ||
| 208697 | 2004-01-20 22:19:00 | Ah, thanks Chill, that worked. :-) I thought that default=1 must have been the key to it, but for some bizarre and utterly illogical reason, I assumed that everything would start with 1 ;-) I never thought that the first boot option would be 0 and the second would be 1... And yes, Fedora keeps grub in /etc/ and I should have made a backup first. Especially as a noob. Thanks again. John |
John H (8) | ||
| 208698 | 2004-01-20 23:18:00 | Reading this thread has prompted me to investigate GRUB - have been a happy LILO user until now! Have a look at: www.gnu.org for an on line manual. To set the first entry as default use: default 0 If things do stuff up, place your first install CD into the drive and type: linux rescue at the prompt. You eventually get to a full working version of your system within another directory. For things to work properly you need to issue the command: chroot name_of_directory_installed_into |
JohnD (509) | ||
| 1 2 | |||||