Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I did run preupgrade to upgrade my Fedora 16(x64) to Fedora 17. And it seemed to work fine. So I got the new gimp 2.8, gcc 4.7.0 and so on. But the system keeps using the old kernel from fc16. Uname -a gives me:

Linux localhost.localdomain 3.3.6-3.fc16.x86_64 #1 SMP Wed May 16 21:43:01 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

The system downloaded the new kernel, so I got

/boot/vmlinuz-3.3.7-1.fc17.x86_64
/boot/System.map-3.3.7-1.fc17.x86_64
/boot/initramfs-3.3.7-1.fc17.x86_64.img
/boot/config-3.3.7-1.fc17.x86_64

But the system keeps using the old kernel from fc16.

If i look at my /boot/grub2/grub.cfg file, it looks like this:

#
# 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="0"
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 (3.3.6-3.fc16.x86_64)' --class fedora --class gnu-linux --class gnu --class os {
    load_video
    set gfxpayload=keep
    insmod gzio
    insmod part_gpt
    insmod ext2
    set root='(hd0,gpt2)'
    search --no-floppy --fs-uuid --set=root 3521a578-5829-4fb4-a485-8c097df77d07
    echo 'Loading Fedora (3.3.6-3.fc16.x86_64)'
    linux   /vmlinuz-3.3.6-3.fc16.x86_64 root=UUID=57459a16-97a0-46a4-8e71-cc3ec0ca4a3e ro  KEYTABLE=dvorak rd.lvm=0 rd.dm=0 quiet SYSFONT=latarcyrheb-sun16 rhgb rd.md.uuid=60956781:734d95ba:424311e2:796702a7 rd.luks=0 LANG=en_US.UTF-8
    echo 'Loading initial ramdisk ...'
    initrd /initramfs-3.3.6-3.fc16.x86_64.img
}
menuentry 'Fedora (3.3.5-2.fc16.x86_64)' --class fedora --class gnu-linux --class gnu --class os {
    load_video
    set gfxpayload=keep
    insmod gzio
    insmod part_gpt
    insmod ext2
    set root='(hd0,gpt2)'
    search --no-floppy --fs-uuid --set=root 3521a578-5829-4fb4-a485-8c097df77d07
    echo 'Loading Fedora (3.3.5-2.fc16.x86_64)'
    linux   /vmlinuz-3.3.5-2.fc16.x86_64 root=UUID=57459a16-97a0-46a4-8e71-cc3ec0ca4a3e ro  KEYTABLE=dvorak rd.lvm=0 rd.dm=0 quiet SYSFONT=latarcyrheb-sun16 rhgb rd.md.uuid=60956781:734d95ba:424311e2:796702a7 rd.luks=0 LANG=en_US.UTF-8
    echo 'Loading initial ramdisk ...'
    initrd /initramfs-3.3.5-2.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 ###
### 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 ###

Anyone got a clue about why it still only references the fc16 kernel, and how I can upgrade it.

My system is using raid1 on 2 disks, but /boot is not using raid. Mount for /boot is:

/dev/sda2 on /boot type ext2 (rw,relatime,seclabel,user_xattr,acl,barrier=1)

And / (The only other filesystem I have) is mounted as

/dev/md0 on / type ext4 (rw,relatime,seclabel,user_xattr,acl,barrier=1,data=ordered)

share|improve this question
    
Does ln -s /etc/grub2.cfg show that it is a link to /boot/grub2/grub.cfg ? – Paul May 30 '12 at 0:11
    
/etc/grub2.cfg -> ../boot/grub2/grub.cfg – MTilsted May 30 '12 at 0:16
    
If you do grub2-mkconfig it will output a grub.cfg to the screen (only) can you take a look at that and see if it picks up the new kernels correctly? – Paul May 30 '12 at 1:43
    
It pick up the correct kernel, and after copying it to /boot/grub2/grub.cfg anything works again :} – MTilsted May 30 '12 at 12:22
    
Since it's working, please accept the answer that resolved your issue. – Michael Hampton Feb 16 '13 at 21:29
up vote 1 down vote accepted

If Paul's advice in the comment above works, you want to persist the change as follows:

su -c "grub2-mkconfig -o /boot/grub2/grub.cfg"
share|improve this answer
    
Yeah, but it doesn't explain why this happened. – Paul May 30 '12 at 3:11
    
RPM packages allow for actions to be triggered pre-installation, post-installation and post-transaction; likely the grub2 package triggered installation of the build loader too soon (before the new kernels were installed, perhaps in %post instead of in %posttrans). Perhaps filing a bug in bugzilla.redhat.com would be in order? A lot of us testers upgraded to F17 pre-releases long time ago (and fix our grub install by hand) so maybe straight updates from F16 are not as well tested – michel-slm May 30 '12 at 4:13
    
I added a bugrepport at bugzilla.redhat.com/show_bug.cgi?id=826529 – MTilsted May 30 '12 at 12:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .