Hello,
I need help with a GRUB2 issue.
Yesterday I did a preupgrade from F15 to F16.
I've added a new custom menu entry for grub in /etc/grub.d/40_custom
After running grub2-mkconfig -o /boot/grub2/grub.cfg, I saw that /boot/grub2/grub.cfg was not updated.
grub2-mkconfig -o /boot/grub2/grub.cfg Generating grub.cfg ... Found linux image: /boot/vmlinuz-3.1.0-5.fc16.x86_64 Found initrd image: /boot/initramfs-3.1.0-5.fc16.x86_64.img No volume groups found Found Windows 7 (loader) on /dev/sda1 Found Mac OS X on /dev/sda3
Instead /boot/grub2/grub.cfg.new was created, and it did not contain my custom menu entry.
What am I doing wrong ? Am I missing a step ?
Below you can see the contents of the following files: /boot/grub2/grub.cfg, /boot/grub2/grub.cfg.new and /etc/grub.d/40_custom
cat /etc/grub.d/40_custom #!/bin/sh exec tail -n +3 $0 # 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. menuentry "Mac OS X 10.6.8" { set root=(hd0,3) chainloader +1 }
cat /boot/grub2/grub.cfg.new # # DO NOT EDIT THIS FILE # # It is automatically generated by grub2-mkconfig using templates # from /etc/grub.d and settings from /etc/default/grub #
### BEGIN /etc/grub.d/00_header ### if [ -s $prefix/grubenv ]; then load_env fi set default="${saved_entry}" if [ "${prev_saved_entry}" ]; then set saved_entry="${prev_saved_entry}" save_env saved_entry set prev_saved_entry= save_env prev_saved_entry set boot_once=true fi
function savedefault { if [ -z "${boot_once}" ]; then saved_entry="${chosen}" save_env saved_entry fi }
function load_video { insmod vbe insmod vga insmod video_bochs insmod video_cirrus }
set timeout=5 ### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/10_linux ### menuentry 'Fedora Linux, with Linux 3.1.0-5.fc16.x86_64' --class fedora --class gnu-linux --class gnu --class os { load_video set gfxpayload=keep insmod gzio insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' linux /boot/vmlinuz-3.1.0-5.fc16.x86_64 root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' initrd /boot/initramfs-3.1.0-5.fc16.x86_64.img } menuentry 'Fedora Linux, with Linux 3.1.0-5.fc16.x86_64 (recovery mode)' --class fedora --class gnu-linux --class gnu --class os { load_video set gfxpayload=keep insmod gzio insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' linux /boot/vmlinuz-3.1.0-5.fc16.x86_64 root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro single rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' initrd /boot/initramfs-3.1.0-5.fc16.x86_64.img } ### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ### ### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/30_os-prober ### menuentry "Windows 7 (loader) (on /dev/sda1)" --class windows --class os { insmod part_msdos insmod ntfs set root='(hd0,msdos1)' search --no-floppy --fs-uuid --set=root 5C3EB3CE3EB39F86 chainloader +1 }
cat /boot/grub2/grub.cfg # # DO NOT EDIT THIS FILE # # It is automatically generated by grub2-mkconfig using templates # from /etc/grub.d and settings from /etc/default/grub #
### BEGIN /etc/grub.d/00_header ### if [ -s $prefix/grubenv ]; then load_env fi if [ "${prev_saved_entry}" ]; then set saved_entry="${prev_saved_entry}" save_env saved_entry set prev_saved_entry= save_env prev_saved_entry set boot_once=true fi
function savedefault { if [ -z "${boot_once}" ]; then saved_entry="${chosen}" save_env saved_entry fi }
function load_video { true }
set timeout=5 ### END /etc/grub.d/00_header ###
### BEGIN /etc/grub.d/10_linux ### menuentry 'Fedora Linux, with Linux 3.1.0-5.fc16.x86_64' --class fedora --class gnu-linux --class gnu --class os { load_video set gfxpayload=keep insmod gzio insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' linux /boot/vmlinuz-3.1.0-5.fc16.x86_64 root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' initrd /boot/initramfs-3.1.0-5.fc16.x86_64.img } menuentry 'Fedora Linux, with Linux 3.1.0-5.fc16.x86_64 (recovery mode)' --class fedora --class gnu-linux --class gnu --class os { load_video set gfxpayload=keep insmod gzio insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' linux /boot/vmlinuz-3.1.0-5.fc16.x86_64 root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro single rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' initrd /boot/initramfs-3.1.0-5.fc16.x86_64.img } ### END /etc/grub.d/10_linux ###
### BEGIN /etc/grub.d/20_linux_xen ### submenu "Xen 4.1" { menuentry 'Fedora Linux, with Xen 4.1 and Linux 3.1.0-5.fc16.x86_64' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen 4.1 ...' multiboot /boot/xen-4.1.gz placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } menuentry 'Fedora Linux, with Xen 4.1 and Linux 3.1.0-5.fc16.x86_64 (recovery mode)' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen 4.1 ...' multiboot /boot/xen-4.1.gz placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro single rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } } submenu "Xen 4.1.1" { menuentry 'Fedora Linux, with Xen 4.1.1 and Linux 3.1.0-5.fc16.x86_64' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen 4.1.1 ...' multiboot /boot/xen-4.1.1.gz placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } menuentry 'Fedora Linux, with Xen 4.1.1 and Linux 3.1.0-5.fc16.x86_64 (recovery mode)' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen 4.1.1 ...' multiboot /boot/xen-4.1.1.gz placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro single rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } } submenu "Xen syms-4.1.1" { menuentry 'Fedora Linux, with Xen syms-4.1.1 and Linux 3.1.0-5.fc16.x86_64' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen syms-4.1.1 ...' multiboot /boot/xen-syms-4.1.1 placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } menuentry 'Fedora Linux, with Xen syms-4.1.1 and Linux 3.1.0-5.fc16.x86_64 (recovery mode)' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen syms-4.1.1 ...' multiboot /boot/xen-syms-4.1.1 placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro single rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } } submenu "Xen xen" { menuentry 'Fedora Linux, with Xen xen and Linux 3.1.0-5.fc16.x86_64' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen xen ...' multiboot /boot/xen.gz placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } menuentry 'Fedora Linux, with Xen xen and Linux 3.1.0-5.fc16.x86_64 (recovery mode)' --class fedora --class gnu-linux --class gnu --class os --class xen { insmod part_msdos insmod ext2 set root='(hd0,msdos2)' search --no-floppy --fs-uuid --set=root a935b93d-51a2-4057-80ab-841a5699bf17 echo 'Loading Xen xen ...' multiboot /boot/xen.gz placeholder echo 'Loading Linux 3.1.0-5.fc16.x86_64 ...' module /boot/vmlinuz-3.1.0-5.fc16.x86_64 placeholder root=UUID=a935b93d-51a2-4057-80ab-841a5699bf17 ro single rd.md=0 rd.lvm=0 rd.dm=0 KEYTABLE=us quiet SYSFONT=latarcyrheb-sun16 rhgb rd.luks=0 LANG=en_US.UTF-8 echo 'Loading initial ramdisk ...' module /boot/initramfs-3.1.0-5.fc16.x86_64.img } } ### END /etc/grub.d/20_linux_xen ###
### BEGIN /etc/grub.d/30_os-prober ### menuentry "Windows 7 (loader) (on /dev/sda1)" --class windows --class os { insmod part_msdos insmod ntfs set root='(hd0,msdos1)' search --no-floppy --fs-uuid --set=root 5C3EB3CE3EB39F86 chainloader +1 } ### 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 ###
### BEGIN /etc/grub.d/41_custom ### if [ -f $prefix/custom.cfg ]; then source $prefix/custom.cfg; fi ### END /etc/grub.d/41_custom ###
### BEGIN /etc/grub.d/90_persistent ### ### END /etc/grub.d/90_persistent ###
On 03/11/11 09:12, Nicolae Ghimbovschi wrote:
Hello,
I need help with a GRUB2 issue.
Yesterday I did a preupgrade from F15 to F16.
<snipped>
You may get more help on the test list. They have benn using grub2 for a while longer: https://admin.fedoraproject.org/mailman/listinfo/test
Thanks !
On Thu, Nov 3, 2011 at 11:23, Frank Murphy frankly3d@gmail.com wrote:
On 03/11/11 09:12, Nicolae Ghimbovschi wrote:
Hello,
I need help with a GRUB2 issue.
Yesterday I did a preupgrade from F15 to F16.
<snipped>
You may get more help on the test list. They have benn using grub2 for a while longer: https://admin.fedoraproject.org/mailman/listinfo/test
-- Regards,
Frank Murphy UTF_8 Encoded Friend of fedoraproject.org -- users mailing list users@lists.fedoraproject.org To unsubscribe or change subscription options: https://admin.fedoraproject.org/mailman/listinfo/users Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
On 03/11/11 17:12, Nicolae Ghimbovschi wrote:
Hello,
I need help with a GRUB2 issue.
Yesterday I did a preupgrade from F15 to F16.
I've added a new custom menu entry for grub in /etc/grub.d/40_custom
After running grub2-mkconfig -o /boot/grub2/grub.cfg, I saw that /boot/grub2/grub.cfg was not updated.
Not sure if you're seeing the same issue I had, but I had a similar problem with grub2 a week or two back. The cfg file was not getting updated. I tracked it down to a bug in this file
/etc/grub.d/30_os-prober
It made reference to grub-probe when it should have been grub2-probe. This was causing grub2-mkconfig to fail to update the file (without an error message too). Replacing grub-probe with grub2-probe in that file might help.
Alternatively adding the following to /etc/grub/default will disable the os prober (if you don't need it anyway, ie if you're not dual/tripple booting etc)
GRUB_DISABLE_OS_PROBER=true
On Thu, 03 Nov 2011 18:46:56 +0800, IC (Ian) wrote:
Not sure if you're seeing the same issue I had, but I had a similar problem with grub2 a week or two back. The cfg file was not getting updated. I tracked it down to a bug in this file
/etc/grub.d/30_os-prober
It made reference to grub-probe when it should have been grub2-probe.
Which is related to the macosx boot entry creation only, however: https://bugzilla.redhat.com/737203
Thanks! I have applied the patch and it worked :)
changed the following in the /etc/grub.d/30_os-prober OSXUUID="`grub-probe --target=fs_uuid --device ${DEVICE} 2> /dev/null`"
to
OSXUUID="`grub2-probe --target=fs_uuid --device ${DEVICE} 2> /dev/null`"
On Thu, Nov 3, 2011 at 12:59, Michael Schwendt mschwendt@gmail.com wrote:
On Thu, 03 Nov 2011 18:46:56 +0800, IC (Ian) wrote:
Not sure if you're seeing the same issue I had, but I had a similar problem with grub2 a week or two back. The cfg file was not getting updated. I tracked it down to a bug in this file
/etc/grub.d/30_os-prober
It made reference to grub-probe when it should have been grub2-probe.
Which is related to the macosx boot entry creation only, however: https://bugzilla.redhat.com/737203
-- Fedora release 16 (Verne) - Linux 3.1.0-5.fc16.x86_64 loadavg: 0.05 0.05 0.07 -- users mailing list users@lists.fedoraproject.org To unsubscribe or change subscription options: https://admin.fedoraproject.org/mailman/listinfo/users Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
On Thu, 2011-11-03 at 13:15 +0200, Nicolae Ghimbovschi wrote:
Thanks! I have applied the patch and it worked :)
changed the following in the /etc/grub.d/30_os-prober OSXUUID="`grub-probe --target=fs_uuid --device ${DEVICE} 2> /dev/null`"
to
OSXUUID="`grub2-probe --target=fs_uuid --device ${DEVICE} 2> /dev/null`"
I applied that patch and modified my /etc/default/grub file in order to change the colors of the text, as seen in [1]:
$ cat /etc/default/grub GRUB_CMDLINE_LINUX="quiet rhgb" GRUB_COLOR_NORMAL="light-blue/black" GRUB_COLOR_HIGHLIGHT="light-cyan/blue"
and then updated:
$ sudo grub2-mkconfig -o /boot/grub2/grub.cfg
...but no luck! Any help?
[1] https://wiki.archlinux.org/index.php/GRUB2#Menu_colors
On Thu, Nov 3, 2011 at 12:59, Michael Schwendt mschwendt@gmail.com wrote:
On Thu, 03 Nov 2011 18:46:56 +0800, IC (Ian) wrote:
Not sure if you're seeing the same issue I had, but I had a similar problem with grub2 a week or two back. The cfg file was not getting updated. I tracked it down to a bug in this file
/etc/grub.d/30_os-prober
It made reference to grub-probe when it should have been grub2-probe.
Which is related to the macosx boot entry creation only, however: https://bugzilla.redhat.com/737203
-- Fedora release 16 (Verne) - Linux 3.1.0-5.fc16.x86_64 loadavg: 0.05 0.05 0.07 -- users mailing list users@lists.fedoraproject.org To unsubscribe or change subscription options: https://admin.fedoraproject.org/mailman/listinfo/users Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
On 03/11/11 18:59, Michael Schwendt wrote:
It made reference to grub-probe when it should have been grub2-probe.
Which is related to the macosx boot entry creation only, however: https://bugzilla.redhat.com/737203
I wasn't aware of that but I do indeed have two HFS+ partitions.