QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 1143|回复: 7

请问2.6的内核与2.4的内核可不可以共存??

[复制链接]
发表于 2003-12-23 15:26:13 | 显示全部楼层 |阅读模式
安装完modules-init-tools包
使用如下命令将modules转换为modprobe.conf
/generate-modprobe.conf /etc/modprobe.conf
转换完成后将modules.conf移除或更名。
再用2.4的内核进入时,网卡和声卡就无法驱动了。
显示“无法打开或找到/dev/mixer”
8139的网卡无法自动找到硬件。

是不是2.4.*的内核与.6.*的无法同时在一个机器上使用啊???
发表于 2003-12-23 15:45:34 | 显示全部楼层
答案是肯定的

2.6 和2.4是可以共存的

http://www.linuxfans.org/nuke/modules.php?name=Forums&file=viewtopic&t=48332
回复

使用道具 举报

 楼主| 发表于 2003-12-23 16:21:46 | 显示全部楼层
2.4.20要用的modules.conf移除或更名后,2.4.20能否找到modules???
回复

使用道具 举报

发表于 2003-12-24 01:53:36 | 显示全部楼层
其实何必呢,我现在已经不打算再用2.4了
因为2.6比2.4强多了
花点时间好好配置配置,彻底投入2.6的怀抱吧
回复

使用道具 举报

发表于 2003-12-28 10:42:23 | 显示全部楼层

Re: 请问2.6的内核与2.4的内核可不可以共存??

[quote:565c4ac78b="ShadowStar"]安装完modules-init-tools包
使用如下命令将modules转换为modprobe.conf
/generate-modprobe.conf /etc/modprobe.conf
转换完成后将modules.conf移除或更名。
再用2.4的内核进入时,网卡和声卡就无法驱动了。
显示“无法打开或找到/dev/mixer”
8139的网卡无法自动找到硬件。

是不是2.4.*的内核与.6.*的无法同时在一个机器上使用啊???[/quote]

To make kernel 2.4 get along well with kernel 2.6, my solution on RH9 is:

1. keep both the /etc/modules.conf and /etc/modprobe.conf, and rename all the necessary modules' names in /etc/modprobe.conf, such as usb,network card(eg. my network card is one of BroadCom 4400 series, its module name in kernel 2.4 is bcm4400, but in kernel 2.6 it's been renamed as b44),etc.
2. make a directory in /etc, say myscripts, then cd into the directory, make 3 subdirectories named 2.4, 2.6, def (or what ever you like), then copy /etc/rc.sysinit to these 3 directories. as result, you'll get 3 rc.sysinit files,each in /etc/myscripts/2.4,  /etc/myscripts/2.6 and /etc/myscripts/def
3. edit your /etc/myscripts/2.6/rc.sysinit, rename all the symbols that are renamed in kernel 2.6, such as ksyms to kallsyms.
4. edit your /etc/rc.sysinit, clear all its original content, input as following:
KERNEL_VERSION=`/bin/uname -r|/bin/cut -c -3`
if [ "$KERNEL_VERSION" = "2.4" ]; then
. /etc/myscripts/2.4/rc.sysinit
elif [ "$KERNEL_VERSION" = "2.6" ]; then
. /etc/myscripts/2.6/rc.sysinit
else
. /etc/myscripts/def/rc.sysinit
fi
5. check again carefully, before you reboot your machine :-)

Cheers
回复

使用道具 举报

发表于 2004-1-6 19:37:52 | 显示全部楼层
我这样改了,只是提示似乎多了些,还是能正常启动
回复

使用道具 举报

发表于 2004-1-6 19:40:55 | 显示全部楼层
if [ "$KERNEL_VERSION" = "2.4" ]; then
. /etc/myscripts/2.4/rc.sysinit
elif [ "$KERNEL_VERSION" = "2.6" ]; then
. /etc/myscripts/2.6/rc.sysinit
else
. /etc/myscripts/def/rc.sysinit
fi
能不能加点脚本,比如启动2.6时自动重命名/etc/modules.conf为modules.conf.bak,启动2.4时自动重命名/etc/modprobe.conf为modprobe.conf.bak?
回复

使用道具 举报

发表于 2004-1-12 13:38:21 | 显示全部楼层
我的还没有编译!不知道该怎么做!今天回去试试安装!
回复

使用道具 举报

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

本版积分规则

GMT+8, 2024-10-6 12:27 , Processed in 0.042269 second(s), 15 queries .

© 2021 Powered by Discuz! X3.5.

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