ajinn 发表于 2005-11-17 21:41:17

编译netfilter模块后不能正常运行iptables

make modules install之后
# iptables -L                                                         
FATAL: Error inserting ip_tables (/lib/modules/2.6.14-686/net/ipv4/netfilter/ip_tables.ko): Unknown symbol in module, or unknown parameter (see dmesg)

#dmesg|grep ip_tables
ip_tables: no version for "struct_module" found: kernel tainted.
ip_tables: Unknown symbol nf_register_sockopt
ip_tables: Unknown symbol nf_unregister_sockopt
ip_tables: Unknown symbol nf_register_sockopt
ip_tables: Unknown symbol nf_unregister_sockopt

linky_fan 发表于 2005-11-19 22:31:11


编译netfilter模块后不能正常运行iptables

only a module or the whole kenel and the kenel_moduels?

ajinn 发表于 2005-11-20 16:25:29

only a module,
试了直接cp编译好的ko文件到/lib/modules…和make module install

linky_fan 发表于 2005-11-20 22:32:40


试了直接cp编译好的ko文件到/lib/modules…和make module install

:shock::shock:

cp编译好的ko文件到/lib/modules ----> modprobe

make module install --------> it's wrong..........................

ajinn 发表于 2005-11-21 23:43:49


make module install --------> it's wrong..........................
WHY?

linky_fan 发表于 2005-11-22 20:12:22


only a module,
试了直接cp编译好的ko文件到/lib/modules…和make module install

If you make only a module , the System.map in your /path/to/kernel/src/ will only contain one module map which was built before, in other words, the modules in the /lib/modules/2.x.x which were there before will be fully lost.   cp it to the /lib/modules/2.x.x/ and modprobe....... is a good way.

Ifyou make the whole kernel(include the bzImage, the modules), then make modules_install

Here is a usefull link , good luck ^-^
http://www.chinaitlab.com/www/news/article_show.asp?id=37488

ajinn 发表于 2005-11-22 21:46:25

我不需要加ipp2p其他模块,只要netfilter模块,所以make xconfig选上netfilter模块然后编译
modprobe时提示Invalid module format
iptables没有重编,我想这个应该没关系吧

linky_fan 发表于 2005-11-22 22:14:44


Invalid module format

.ko or .o?

ajinn 发表于 2005-11-23 20:58:03

.ko
# modprobe ip_tables
FATAL: Error inserting ip_tables (/lib/modules/2.6.14-686/kernel/net/ipv4/netfilter/ip_tables.ko): Invalid module format
页: [1]
查看完整版本: 编译netfilter模块后不能正常运行iptables