LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 536|回复: 1

按照置顶贴:"Sarge 下一步一步编译 Debian 内核" 编译升级内核出

[复制链接]
发表于 2007-4-6 14:06:55 | 显示全部楼层 |阅读模式
根据http://www.howtoforge.com/kernel_compilation_debian此文,我的当前内核是2.4.27升级到2.6.20.4

做到第8步:
8 Create A Ramdisk

Now we must create a ramdisk for our new kernel. Normally we do this with mkinitrd, but our new kernel uses udev instead of devfs, and you'll most likely get this error message with an mkinitrd generated ramdisk during boot-up:

mount: unknown filesystem type 'devfs'

which might lead to a kernel panic.

The new way of creating ramdisks is with mkinitrd.yaird. Backports.org has a yaird package for Debian Sarge. Before we can install it, we must install two prerequisites:

apt-get install libhtml-template-perl libparse-recdescent-perl

Then we install yaird like this:

cd /tmp
wget http://downloads.howtoforge.com/files/yaird_0.0.12-8bpo1_i386.deb
dpkg -i yaird_0.0.12-8bpo1_i386.deb

(The original yaird package was located in http://backports.org/debian/pool/main/y/yaird/, but was removed in the meantime, so I've made the package available under http://downloads.howtoforge.com/files/yaird_0.0.12-8bpo1_i386.deb.)

Before we can create the new ramdisk, we must edit the configuration file of our new kernel which you can find in the /boot directory (run

ls -l /boot

to find out). In this tutorial it's called /boot/config-2.6.18.3-default1, and in that file we must comment out the line CONFIG_DEFCONFIG_LIST (towards the beginning of the file) because otherwise mkinitrd.yaird will throw an error like this at us:

yaird error: bad value in /boot/config-2.6.18.3-default1: CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" (fatal)

So we do this:

vi /boot/config-2.6.18.3-default1

[...]
# CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"
[...]

Now we can finally create our ramdisk like this:
运行此语句出错:
[color="Red"]mkinitrd.yaird -o /boot/initrd.img-2.6.18.3-default1 2.6.18.3-default1
错误信息:
[color="Red"]yaird error: can't open /proc/bus/input/devices (fatal)
然后我查看该目录,发现/proc/bus下没有input目录。
这是什么原因呢?在menuconfig时,我是先load 2.4的.config,然后没做改动再保存。是需要配置什么吗?:ask :ask :ask :ask
发表于 2007-4-7 08:13:50 | 显示全部楼层
是否欠缺 psuedo filesystem 的支持?
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表