Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
i had Fedora 15, and Centos 5.5 in my pc, fedora in a hard disk (/dev/sda) and centos in another hard disk (/dev/sdb)
i add third hard disk (/dev/sdc) and install ubuntu 10.4 in it. after installing ubuntu, centos gone from grub list, in grub there is just ubuntu and fedora.
how can i fix it?!
i try grub recovery and just found ubuntu and fedora, not centos.
tanx.
root@ardaneh-ubuntu:~# mkdir /media/centos
root@ardaneh-ubuntu:~# mount /dev/sdb2 /media/centos/
root@ardaneh-ubuntu:~# ls /media/centos/
bin boot dev etc home lib lost+found media misc mnt opt poweroff proc root sbin selinux srv sys tftpboot tmp usr var
root@ardaneh-ubuntu:~# update-grub
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-50-generic-pae
Found initrd image: /boot/initrd.img-2.6.32-50-generic-pae
Found memtest86+ image: /memtest86+.bin
Found Fedora release 15 (Lovelock) on /dev/sda2
Found CentOS release 5.9 (Final) on /dev/sdb2
done
root@ardaneh-ubuntu:~# cat /boot/grub/grub.cfg
...
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Ubuntu, with Linux 2.6.32-50-generic-pae' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd2,1)'
search --no-floppy --fs-uuid --set c7f7ea49-4178-404b-8460-2d723ecc2c38
linux /vmlinuz-2.6.32-50-generic-pae root=UUID=6909eb58-c9fe-469c-808c-0f5685bba641 ro quiet splash
initrd /initrd.img-2.6.32-50-generic-pae
}
menuentry 'Ubuntu, with Linux 2.6.32-50-generic-pae (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
insmod ext2
set root='(hd2,1)'
search --no-floppy --fs-uuid --set c7f7ea49-4178-404b-8460-2d723ecc2c38
echo 'Loading Linux 2.6.32-50-generic-pae ...'
linux /vmlinuz-2.6.32-50-generic-pae root=UUID=6909eb58-c9fe-469c-808c-0f5685bba641 ro single
echo 'Loading initial ramdisk ...'
initrd /initrd.img-2.6.32-50-generic-pae
}
### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod ext2
set root='(hd2,1)'
search --no-floppy --fs-uuid --set c7f7ea49-4178-404b-8460-2d723ecc2c38
linux16 /memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod ext2
set root='(hd2,1)'
search --no-floppy --fs-uuid --set c7f7ea49-4178-404b-8460-2d723ecc2c38
linux16 /memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###
### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Fedora (2.6.40.6-0.fc15.x86_64) (on /dev/sda2)" {
insmod ext2
set root='(hd0,1)'
search --no-floppy --fs-uuid --set e889a008-6616-4388-a1ed-fc9e2b8b35b0
linux /vmlinuz-2.6.40.6-0.fc15.x86_64 ro root=UUID=82b3a603-bbb9-4c45-bd36-e899592576e4 rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYTABLE=us rhgb quiet
initrd /initramfs-2.6.40.6-0.fc15.x86_64.img
}
### END /etc/grub.d/30_os-prober ###
### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###
root@ardaneh-ubuntu:~#
root@ardaneh-ubuntu:~# update-grub
Generating grub.cfg ...
Found linux image: /boot/vmlinuz-2.6.32-50-generic-pae
Found initrd image: /boot/initrd.img-2.6.32-50-generic-pae
Found memtest86+ image: /memtest86+.bin
Found Fedora release 15 (Lovelock) on /dev/sda2
Found CentOS release 5.9 (Final) on /dev/sdb2
done
yes, i do it many times after "update-grub" from ubuntu/terminal and from ubuntu recovery mode, but every time i reboot in grub just ubuntu, ubuntu recovery, memory test and fedora appear. there is no line for centos.
the first thing you noticed was that your menu was missing a detected OS
but notice that the first entries are for ubuntu
---so you must have have booted into ubuntu or you must have had ubuntu install its grub into MBR of something and take over.
Ideally as each drive has a mbr......but we don't know your bios boot order.....I suggest you want fedora on sda to be the controlling grub?
so try manual commands to get in
at grub menu press C for commands
Code:
set root=(hd0,2)
linux /boot/vml (and press TAB key to autocomplete kernel name,
----you must see something that resembles fedora or I have it wrong so don't continue this way
(lets pretend)
linux /boot/vmlinuz-fedora root=/dev/sda2
initrd /boot/init (and press TAB key to auto complete and choose the matching k to initrd numbers
boot
you have just booted into fedora....assuming grub2 now fix up fedora grub2
Code:
sudo grub-install /dev/sda
re-puts fedora's grub into mbr of sda
may or may not find the other 2 OS but I assume you have os-prober installed in fedora
good luck
#####
set root=(hd0,2) tells grub to look for fedora's /boot partition at hd0,2
if you have a separate /boot partition to / for fedora then change it twice
once for the set root command and drop the leading /boot from the linux and initrd line
Distribution: Cinnamon Mint 20.1 (Laptop) and 20.2 (Desktop)
Posts: 1,672
Rep:
I'm having the same problem after installing Ubuntu 12.04 which has re-written the Grub config files and my Centos system is missing. It may be because Centos uses LVM and I've got it installed over an 8 disk RAID (Yes, I know, total overkill and pointless.) The volume shows up as /dev/cciss0 or something, it's on an HP SmartArray.
The last time I got it working, I had to manually "knit" the 40_custom file to get it to be recognised. So far it gives me "Centos" as a boot option but can't find the kernel. (It was 01:00 this morning when I gave up so I've still a bit of work to do.) I had to define the Root volume by its UUID which worked last time.
Interesting that your system acknowledgd that you had Centos as a choice, mine never has.
tanx everyone for all of your suggestion,
i can not use them but i learn many things
i finally replace ubuntu 12.04.2 Desktop edition with ubuntu 10.4 and my problem solved.
now in grub i have ubuntu, fedora and centos together.
tanx everyone for all of your suggestion,
i can not use them but i learn many things
i finally replace ubuntu 12.04.2 Desktop edition with ubuntu 10.4 and my problem solved.
now in grub i have ubuntu, fedora and centos together.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.