Problem Booting Multiple Linux
Hello,
I'm trying to configure multiple Linux booting in one PC. Here's output of "fdisk -l" Code:
Device Boot Start End Blocks Id System I want to add other Linuxes on other partitions & boot them using RHEL5's grub. So, I've installed Fedora_16 on /dev/hda3, without installing it's grub. Then added some "chainloader +1" rules in /etc/grub.conf: Quote:
How to solve this? Thanks. |
might help
grub can write its own grub.cfg Make sure all partitions are mounted
In a terminal do: sudo update-grub (takes a while, especially as you have a lot of partitions) I am no expert, but I've never seen chainloader +1 in a Linux grub.cfg entry, except for Windows. Typical entry for Fedora, which you can find in (Fedora partition) /boot/grub2/grub.cfg menuentry 'Fedora (3.5.2-1.fc17.x86_64)' --class fedora --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-710cdbf5-48ff-484d-b1f8-9a143a78dbec' { load_video set gfxpayload=keep insmod gzio insmod part_msdos insmod ext2 set root='hd0,msdos6' if [ x$feature_platform_search_hint = xy ]; then search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos6 --hint-efi=hd0,msdos6 --hint-baremetal=ahci0,msdos6 --hint='hd0,msdos6' 710cdbf5-48ff-484d-b1f8-9a143a78dbec else search --no-floppy --fs-uuid --set=root 710cdbf5-48ff-484d-b1f8-9a143a78dbec fi echo 'Loading Fedora (3.5.2-1.fc17.x86_64)' linux /boot/vmlinuz-3.5.2-1.fc17.x86_64 root=UUID=710cdbf5-48ff-484d-b1f8-9a143a78dbec ro rd.md=0 rd.lvm=0 rd.dm=0 SYSFONT=True KEYTABLE=us rd.luks=0 LANG=en_US.UTF-8 rhgb quiet echo 'Loading initial ramdisk ...' initrd /boot/initramfs-3.5.2-1.fc17.x86_64.img } The problem I see for you is: I have Ubuntu and Fedora. Ubuntu has 'control' of grub at boot. So if it adds a kernel, it does update-grub, which overwrites past entries. I don't usually have both partitions mounted, so it does not find Fedora. After a kernel update, I need to a) mount the Fedora partition b) run sudo update-grub I would like to know how to automate this. For you it is even more important. |
RHEL 5 uses Grub, not Grub2, so your script won't work here, Pedroski.
@cOde13: If you want to chainload a Linux system you must install its bootloader to its root partition. Chainloading means that one bootloader starts the next one, which of course can't work if you don't have one installed. |
I did mention I am no expert! It is not my script, it comes with Linux. I could not write that.
But: I could chainload Fedora from the Ubuntu boot grub.cfg??? Point it at (Fedora partition)/boot/grub2/grub.cfg or how?? Can you tell me what the entry should look like?? That would save me updating Ubuntu grub.cfg every time. |
Thanks for your replies.
Quote:
Is it possible to install Fedora's Grub to it's root partition using "linux rescue"? or, I need to reinstall Fedora? |
Quote:
|
Thanks, I'll work on that.
|
Okay I've find it. :D
Thanks everyone. |
Nice to hear that it works. Please mark this thread as solved using the thread tools at the top of the thread.
|
Not necessarily applicable to this case but - I've normally run 4 to 5 different systems at a time, usually with Deb as prime and Deb grub booting all, no chain except Win. With earlier versions of update-grub, it would create an incorrect entry for Fedora because the boot img file in Fedora was a different name format and unrecognized, causing a boot entry with no img file. Had to manually add it to grub.cfg.
I suspect this would not be the case with only Red Hat and Fedora since I ASSUME they would have the same construction and a Red Hat grub should correctly handle a Fedora construct. |
Then you will have the same problem as me: update the Deb kernel, and you will wipe out your grub.cfg entries, unless you have all partitions mounted at the time. Why would you do that?
Seems to me chainloading is a good idea for multiple boot systems. Just gotta figure out how to formulate the entries in grub.cfg and the problem of the bootloader. I'm sure I told Fedora not to install the boot loader, as that would wipe out my Ubuntu grub. Hmmm, need to think about this! |
No, that is not the case. When the new Deb kernel installs and updates grub.cfg, it reads the entire disk for OS's and adds them. They don't have to be mounted. The only problem is when it doesn't properly recognize the particular set-up and this is pretty much solved now.
Also, with more current grub installs, if you need to do anything special or manual, you can sudo edit /etc/grub.d/40_custom and add any menu entry you like. When grub updates, it will add anything it finds there to grub.cfg. This could specific boot items or even just a message/reminder to yourself. |
Now I remember why I rather use Lilo instead.
|
You're lucky! If my Fedora partition is not mounted, Ubuntu does not see it. Actually, I've never had it mounted during a kernel update. Next time I'll try.
|
Yes, I am with TobiSGD on this. In order to multiboot Linux you put one Linux Grub (or Lilo) in the MBR and any other Linux you want to multiboot, you'll have to put its bootloader IN HIS OWN ROOT PARTITION otherwise poor grub can't recognize the linux you want to boot when you start your system. I have a multiboot system with 12 Linux,Opensolaris, PCBSD and WINXP with that simple system and everything is working like a charm.Simple system, simple solution.
|
All times are GMT -5. The time now is 12:44 PM. |