LinuxSir.cn,穿越时空的Linuxsir!

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

关于nvidia.ko的问题

[复制链接]
发表于 2011-5-15 10:06:01 | 显示全部楼层 |阅读模式
emerge -DNauv world  升级了nvidia-drivers后就无法startx

xorg.log中的错误信息为:FATAL:error inserting '/lib/modules/.../video/nvidia.ko ': invalid module format

我重新编译了内核,然后再安装nvidia-drivers(无错误提示);但在modprobe nvidia时仍然出现同样的错误提示(内核版本与当前系统所使用的版本一致)。不知道问题到底出在什么地方,求解。
发表于 2011-5-15 10:21:37 | 显示全部楼层
When you attempt to load the kernel module you receive a "insmod: error inserting ... Invalid module format"
This type of error can be diagnosed by running:
dmesg

The output from this command will indicate the source of the problem.

Common reasons for this error include:

    Using the wrong kernel preemption option.
    Your kernel module was compiled with a different gcc version than your kernel. In this case simply re-emerge the kernel and nvidia kernel module.

[edit] Preemption

In this case you'll probably see a message like: should be "<arch><kernel> preempt <gcc version>"

If the kernel is not compiled to be a preemptible kernel then trying to insert the nvidia.ko module will fail. To make the kernel preemptible use your favorite text editor to modify your kernel's configuration file (.config by default) and be sure to ammend: CONFIG_PREEMPT=y

As well as commenting out all other CONFIG_PREEMPT type options.


凑字数~~~~
回复 支持 反对

使用道具 举报

 楼主| 发表于 2011-5-15 12:23:42 | 显示全部楼层
Post by darrenlee;2139179
凑字数~~~~


按照引文中的方法在.config中确认"CONFIG_PREEMPT=y"后重新编译完内核,再次安装nvidia-drivers.结果:
failed to load the module "NVIDIA"(module-specific error 0)
回复 支持 反对

使用道具 举报

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

本版积分规则

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