在VMWare Fusion下的RedHat Linux中引导时出现内核严重错误:找不到文件系统

gMa*_*ale 0 linux kernel redhat linux-kernel vmware-fusion

这应该很简单.然而,它给了我地狱.

问题
我编译了最新的内核,当我重启我的盒子时,它会产生与文件系统相关的内核恐慌.

问题
如何让新内核识别VMWare文件系统?某些地方必须有一些设置让Linux安装知道"硬盘驱动器"不是真正的驱动器,而是实际上代表虚拟机的文件.

背景
首先,我不是Linux大师.这是我第一次编译内核.我为解决这个问题做了什么:

  • 从kernel.org下载内核版本2.6.34
  • 将源解压缩到目录中
  • 按照安装说明进行操作:
  • http://www.cyberciti.biz/tips/compiling-linux-kernel-26.html
  • 基本上,运行:make menuconfig,make,make modules,make modules_install,make install,reboot
  • 我没有真正改变make menuconfig部分中的任何内容

重启后,它失败并出现以下错误:

No volume groups found
Volume group "VolGroup00" not found
Unable to access resume device (/dev/VolGroup00/LogVol01)
mount: could not find filesystem '/dev/root'
setuproot: moving /dev failed: No such file or directory
setuproot: error mounting /proc: No such file or directory
setuproot: error mounting /sys: No such file or directory
switchroot: mount failed: No such file or directory
Kernel panic - not syncing: Attempted to kill init!
Run Code Online (Sandbox Code Playgroud)

环境
我在VMWare Fusion版本3.1.0(261058)下运行Red Hat Enterprise Linux Server(2.6.18-194.3.1.el5PAE),在运行2.8 GHz Intel Core Duo处理器的OS X v10.5.8的MacBook Pro上运行4GB 1067 MHz DDR3内存.虚拟机分配了2个处理器核心和2048 MB内存.VM硬盘设置指向文件"Red Hat Enterprise Linux 5.vmdk","Bus Type"设置为"SCSI","Disk Size"设置为40Gb,"Split into 2Gb Files"选项选中.

当我使用下面的/boot/grub/menu.lst文件时,一切都运行正常,除了它引导到错误的内核(2.6.18-194.3.1.el5PAE而不是2.6.34):

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,0)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/sda
default=1
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Red Hat Enterprise Linux Server (2.6.34)
    root (hd0,0)
    kernel /vmlinuz-2.6.34 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
    initrd /initrd-2.6.34.img
title Red Hat Enterprise Linux Server (2.6.18-194.3.1.el5PAE)
    root (hd0,0)
    kernel /vmlinuz-2.6.18-194.3.1.el5PAE ro root=/dev/VolGroup00/LogVol00 rhgb quiet
    initrd /initrd-2.6.18-194.3.1.el5PAE.img
title Red Hat Enterprise Linux Server (2.6.18-194.el5PAE)
    root (hd0,0)
    kernel /vmlinuz-2.6.18-194.el5PAE ro root=/dev/VolGroup00/LogVol00 rhgb quiet
    initrd /initrd-2.6.18-194.el5PAE.img
Run Code Online (Sandbox Code Playgroud)

当我使用以下文件(最后一行被注释掉,以及其他一些小编辑)时,它会尝试引导正确的内核,但启动失败并导致上述内核崩溃:

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,0)
#          kernel /vmlinuz-version ro root=/dev/VolGroup00/LogVol00
#          initrd /initrd-version.img
#boot=/dev/sda
default=1
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Red Hat Enterprise Linux Server (2.6.34)
    root (hd0,0)
    kernel /vmlinuz-2.6.34 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
    initrd /initrd-2.6.34.img
    savedefault
    boot
#title Red Hat Enterprise Linux Server (2.6.18-194.3.1.el5PAE)
#   root (hd0,0)
#   kernel /vmlinuz-2.6.18-194.3.1.el5PAE ro root=/dev/VolGroup00/LogVol00 rhgb quiet
#   initrd /initrd-2.6.18-194.3.1.el5PAE.img
#title Red Hat Enterprise Linux Server (2.6.18-194.el5PAE)
#   root (hd0,0)
#   kernel /vmlinuz-2.6.18-194.el5PAE ro root=/dev/VolGroup00/LogVol00 rhgb quiet
#   initrd /initrd-2.6.18-194.el5PAE.img
Run Code Online (Sandbox Code Playgroud)

我不明白,在一种情况下,它可以弄清楚VMWare的文件系统就好了,而在另一种情况下,它不能.我错过了什么?是否应该选择一些与VMWare相关的特殊编译选项?我需要更改VMWare Fusion方面的内容吗?我想不出来了!

任何和所有建议都非常感谢!

Yur*_*vin 6

我遇到了类似的问题.

内核比硬件要老得多.SATA默认连接硬盘.我重新配置(在BIOS或VM.Properties中)硬件以通过IDE连接.它对我有用,我很高兴:)