Fedora 17 继续使用 Fedora 16 内核

Fedora 17 继续使用 Fedora 16 内核

我确实运行了 preupgrade 来将我的 Fedora 16(x64) 升级到 Fedora 17。它似乎运行良好。所以我得到了新的 gimp 2.8、gcc 4.7.0 等等。但系统继续使用来自 fc16 的旧内核。Uname -a 给我:

Linux localhost.localdomain 3.3.6-3.fc16.x86_64 #1 SMP 2012 年 5 月 16 日星期三 21:43:01 UTC x86_64 x86_64 x86_64 GNU/Linux

系统下载了新的内核,所以我得到了

/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

但系统继续使用来自fc16的旧内核。

如果我查看我的 /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
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 ###

有人知道为什么它仍然只引用 fc16 内核,以及我如何升级它吗?

我的系统在 2 个磁盘上使用 raid1,但 /boot 没有使用 raid。/boot 的挂载方式为:

/dev/sda2 在 /boot 类型 ext2 上(rw、relatime、seclabel、user_xattr、acl、barrier=1)

并且 / (我拥有的唯一其他文件系统)被挂载为

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

答案1

如果 Paul 在上述评论中的建议有效,您可以按如下方式保留更改:

su -c "grub2-mkconfig -o /boot/grub2/grub.cfg"

相关内容