QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 733|回复: 1

关于模块编程

[复制链接]
发表于 2004-3-17 09:52:37 | 显示全部楼层 |阅读模式
译出来的*.o文件在用insmod命令插入的时候,总是报错,错误有两种:
一:
[root@SUNOS5 root]# insmod firewall.o
firewall.o: kernel-module version mismatch
firewall.o was compiled for kernel version 2.4.20
while this kernel is version 2.4.20-8smp.

二:
[root@SUNOS5 root]# insmod hello.o
hello.o: couldn't find the kernel version the module was compiled for

是不是我编译的命令有问题,应该是怎么的呢,或者是程序里面该加些什么定义呢???
发表于 2004-3-18 00:50:12 | 显示全部楼层
no, u are using redhat kernel, u install from rpm but the kernel source version is mismatch with the running kernel. so u can insmod -f if u are lazy to recompile a kenrel and run that new kernel
回复

使用道具 举报

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

本版积分规则

GMT+8, 2024-10-4 18:39 , Processed in 0.041948 second(s), 16 queries .

© 2021 Powered by Discuz! X3.5.

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