# ip_tables module not loading (fixed)

## Bigun

dmesg showing this output:

```
ip_tables: Unknown symbol xt_free_table_info

ip_tables: Unknown symbol xt_register_match

ip_tables: Unknown symbol xt_find_match

ip_tables: Unknown symbol xt_alloc_table_info

ip_tables: Unknown symbol nf_register_sockopt

ip_tables: Unknown symbol xt_check_match

ip_tables: Unknown symbol xt_unregister_match

ip_tables: Unknown symbol nf_unregister_sockopt

ip_tables: Unknown symbol xt_register_target

ip_tables: Unknown symbol per_cpu__xt_info_locks

ip_tables: Unknown symbol xt_register_table

ip_tables: Unknown symbol xt_proto_init

ip_tables: Unknown symbol xt_replace_table

ip_tables: Unknown symbol xt_find_table_lock

ip_tables: Unknown symbol xt_table_unlock

ip_tables: Unknown symbol xt_proto_fini

ip_tables: Unknown symbol xt_check_target

ip_tables: Unknown symbol xt_find_revision

ip_tables: Unknown symbol xt_unregister_table

ip_tables: Unknown symbol xt_find_target

ip_tables: Unknown symbol xt_unregister_target
```

```
 # emerge --info

Portage 2.1.7.16 (default/linux/x86/10.0, gcc-4.1.2, glibc-2.10.1-r1, 2.6.31-gentoo-r6 i686)

=================================================================

System uname: Linux-2.6.31-gentoo-r6-i686-Pentium_III_-Coppermine-with-gentoo-1.12.13

Timestamp of tree: Tue, 02 Feb 2010 13:00:01 +0000

app-shells/bash:     4.0_p35

dev-java/java-config: 1.3.7-r1, 2.1.9-r2

dev-lang/python:     2.4.4-r13, 2.5.2-r5, 2.6.4

dev-python/pycrypto: 2.1.0_beta1

sys-apps/baselayout: 1.12.13

sys-apps/sandbox:    1.6-r2

sys-devel/autoconf:  2.13, 2.63-r1

sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.2

sys-devel/binutils:  2.18-r3

sys-devel/gcc:       4.1.2, 4.3.4

sys-devel/gcc-config: 1.4.1

sys-devel/libtool:   2.2.6b

virtual/os-headers:  2.6.27-r2

ACCEPT_KEYWORDS="x86"

ACCEPT_LICENSE="* -@EULA"

CBUILD="i686-pc-linux-gnu"

CFLAGS="-march=pentium3 -O2 -pipe -fomit-frame-pointer"

CHOST="i686-pc-linux-gnu"

CONFIG_PROTECT="/etc /var/bind"

CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/udev/rules.d"

CXXFLAGS="-march=pentium3 -O2 -pipe -fomit-frame-pointer"

DISTDIR="/usr/portage/distfiles"

FEATURES="assume-digests distlocks fixpackages news parallel-fetch protect-owned sandbox sfperms strict unmerge-logs unmerge-orphans userfetch"

GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/linux/distributions/gentoo"

LDFLAGS="-Wl,-O1"

MAKEOPTS="-j3"

PKGDIR="/usr/portage/packages"

PORTAGE_CONFIGROOT="/"

PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

SYNC="rsync://rsync.gentoo.org/gentoo-portage"

USE="acl apache2 authdaemond bind-mysql bzip2 cli cracklib crypt ctype cxx dedicated dri fat fortran ftp gd gdbm gif gpm http iconv ident imap ipv6 javascript jpeg jpeg2k libwww lm_sensors maildir mjpeg mmx modules mudflap mysql ncurses nptl nptlonly ntfs offensive openmp pam pcre perl php png pppd python readline reflection reiserfs sasl sendmail session spell spl sse ssl sysfs tcpd tiff truetype unicode vda vhosts x264 x86 xml zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="fbdev glint intel mach64 mga neomagic nv r128 radeon savage sis tdfx trident vesa via vmware voodoo" 

Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
```

Help?

edit:

removed repeated errors.

----------

## d2_racing

Hi, did you enable those inside your kernel ?

----------

## Bigun

```
 # grep "IPTABLE" .config 

CONFIG_IP_NF_IPTABLES=m

# CONFIG_IP6_NF_IPTABLES is not set
```

edit:

or were you talking about these?

```
# grep "NETFILTER_XT" .config 

CONFIG_NETFILTER_XTABLES=y

# CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set

# CONFIG_NETFILTER_XT_TARGET_MARK is not set

# CONFIG_NETFILTER_XT_TARGET_NFLOG is not set

# CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set

# CONFIG_NETFILTER_XT_TARGET_RATEEST is not set

# CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set

# CONFIG_NETFILTER_XT_MATCH_COMMENT is not set

# CONFIG_NETFILTER_XT_MATCH_DCCP is not set

# CONFIG_NETFILTER_XT_MATCH_DSCP is not set

# CONFIG_NETFILTER_XT_MATCH_ESP is not set

# CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set

# CONFIG_NETFILTER_XT_MATCH_HL is not set

# CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set

# CONFIG_NETFILTER_XT_MATCH_LENGTH is not set

# CONFIG_NETFILTER_XT_MATCH_LIMIT is not set

# CONFIG_NETFILTER_XT_MATCH_MAC is not set

# CONFIG_NETFILTER_XT_MATCH_MARK is not set

# CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set

# CONFIG_NETFILTER_XT_MATCH_OWNER is not set

# CONFIG_NETFILTER_XT_MATCH_POLICY is not set

# CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set

# CONFIG_NETFILTER_XT_MATCH_QUOTA is not set

# CONFIG_NETFILTER_XT_MATCH_RATEEST is not set

# CONFIG_NETFILTER_XT_MATCH_REALM is not set

# CONFIG_NETFILTER_XT_MATCH_RECENT is not set

# CONFIG_NETFILTER_XT_MATCH_SCTP is not set

# CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set

# CONFIG_NETFILTER_XT_MATCH_STRING is not set

# CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set

# CONFIG_NETFILTER_XT_MATCH_TIME is not set

# CONFIG_NETFILTER_XT_MATCH_U32 is not set
```

----------

## d2_racing

Yes, you need to enable some netfilter/iptables stuff to be able to use the module :

You need at least this : 

CONFIG_NETFILTER

CONFIG_NF_CONNTRACK

CONFIG_IP_NF_IPTABLES

----------

## Bigun

I've made sure those three things are enabled.... now I'm getting fewer errors at least:

```
ip_tables: Unknown symbol xt_free_table_info

ip_tables: Unknown symbol xt_register_match

ip_tables: Unknown symbol xt_find_match

ip_tables: Unknown symbol xt_alloc_table_info

ip_tables: Unknown symbol nf_register_sockopt

ip_tables: Unknown symbol xt_check_match

ip_tables: Unknown symbol xt_unregister_match

ip_tables: Unknown symbol nf_unregister_sockopt

ip_tables: Unknown symbol xt_register_target

ip_tables: Unknown symbol per_cpu__xt_info_locks

ip_tables: Unknown symbol xt_register_table

ip_tables: Unknown symbol xt_proto_init

ip_tables: Unknown symbol xt_replace_table

ip_tables: Unknown symbol xt_find_table_lock

ip_tables: Unknown symbol xt_table_unlock

ip_tables: Unknown symbol xt_proto_fini

ip_tables: Unknown symbol xt_check_target

ip_tables: Unknown symbol xt_find_revision

ip_tables: Unknown symbol xt_unregister_table

ip_tables: Unknown symbol xt_find_target

ip_tables: Unknown symbol xt_unregister_target
```

edit:

I've found some Gentoo documentation covering the kernel setup to make iptables work.  Lemme try that real quick.

edit:

Nevermind, the kernel structure they give for setting up looks dated.

----------

## d2_racing

So, make sure that you enable them inside your kernel [M], they don't need to be [*].

Also, you should post your new .config that contain your iptables modules too.

----------

## Bigun

.config

----------

## d2_racing

Hi, you should enable them too :

```

# CONFIG_NF_CT_PROTO_UDPLITE is not set

# CONFIG_NF_CONNTRACK_AMANDA is not set

# CONFIG_NF_CONNTRACK_FTP is not set

# CONFIG_NF_CONNTRACK_H323 is not set

# CONFIG_NF_CONNTRACK_IRC is not set

# CONFIG_NF_CONNTRACK_NETBIOS_NS is not set

# CONFIG_NF_CONNTRACK_PPTP is not set

# CONFIG_NF_CONNTRACK_SANE is not set

# CONFIG_NF_CONNTRACK_SIP is not set

# CONFIG_NF_CONNTRACK_TFTP is not set

# CONFIG_NF_CT_NETLINK is not set

CONFIG_NETFILTER_XTABLES=y

# CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set

# CONFIG_NETFILTER_XT_TARGET_CONNMARK is not set

# CONFIG_NETFILTER_XT_TARGET_MARK is not set

# CONFIG_NETFILTER_XT_TARGET_NFLOG is not set

# CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set

# CONFIG_NETFILTER_XT_TARGET_RATEEST is not set

# CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set

# CONFIG_NETFILTER_XT_MATCH_CLUSTER is not set

# CONFIG_NETFILTER_XT_MATCH_COMMENT is not set

# CONFIG_NETFILTER_XT_MATCH_CONNBYTES is not set

# CONFIG_NETFILTER_XT_MATCH_CONNLIMIT is not set

# CONFIG_NETFILTER_XT_MATCH_CONNMARK is not set

# CONFIG_NETFILTER_XT_MATCH_CONNTRACK is not set

# CONFIG_NETFILTER_XT_MATCH_DCCP is not set

# CONFIG_NETFILTER_XT_MATCH_DSCP is not set

# CONFIG_NETFILTER_XT_MATCH_ESP is not set

# CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set

# CONFIG_NETFILTER_XT_MATCH_HELPER is not set

# CONFIG_NETFILTER_XT_MATCH_HL is not set

# CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set

# CONFIG_NETFILTER_XT_MATCH_LENGTH is not set

# CONFIG_NETFILTER_XT_MATCH_LIMIT is not set

# CONFIG_NETFILTER_XT_MATCH_MAC is not set

# CONFIG_NETFILTER_XT_MATCH_MARK is not set

# CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set

# CONFIG_NETFILTER_XT_MATCH_OWNER is not set

# CONFIG_NETFILTER_XT_MATCH_POLICY is not set

# CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set

# CONFIG_NETFILTER_XT_MATCH_QUOTA is not set

# CONFIG_NETFILTER_XT_MATCH_RATEEST is not set

# CONFIG_NETFILTER_XT_MATCH_REALM is not set

# CONFIG_NETFILTER_XT_MATCH_RECENT is not set

# CONFIG_NETFILTER_XT_MATCH_SCTP is not set

# CONFIG_NETFILTER_XT_MATCH_STATE is not set

# CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set

# CONFIG_NETFILTER_XT_MATCH_STRING is not set

# CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set

# CONFIG_NETFILTER_XT_MATCH_TIME is not set

# CONFIG_NETFILTER_XT_MATCH_U32 is not set

# CONFIG_IP_VS is not set

#

# IP: Netfilter Configuration

#

CONFIG_NF_DEFRAG_IPV4=y

CONFIG_NF_CONNTRACK_IPV4=y

CONFIG_NF_CONNTRACK_PROC_COMPAT=y

# CONFIG_IP_NF_QUEUE is not set

CONFIG_IP_NF_IPTABLES=m

# CONFIG_IP_NF_MATCH_ADDRTYPE is not set

# CONFIG_IP_NF_MATCH_AH is not set

# CONFIG_IP_NF_MATCH_ECN is not set

# CONFIG_IP_NF_MATCH_TTL is not set

# CONFIG_IP_NF_FILTER is not set

# CONFIG_IP_NF_TARGET_LOG is not set

# CONFIG_IP_NF_TARGET_ULOG is not set

# CONFIG_NF_NAT is not set

# CONFIG_IP_NF_MANGLE is not set

# CONFIG_IP_NF_TARGET_TTL is not set

# CONFIG_IP_NF_RAW is not set

# CONFIG_IP_NF_ARPTABLES is not set

```

----------

## Bigun

I think we are almost there:

```
ip_tables: Unknown symbol nf_register_sockopt

ip_tables: Unknown symbol nf_unregister_sockopt
```

These are the only two left.  They repeat themselves in the dmesg output about 15 times or so.

Here's the updated .config.

----------

## Bigun

Out of the pot, and into the fire.

I attempted to upgrade the kernel, and now it won't boot... and to add salt to the wound, it won't boot of a live CD either.

I can't resolve this issue until the other gets solved.

----------

## Bigun

I'm booting again, this time with grub so I can make changes on the fly.

For some reason I can't get gentoo-sources-2.6.35-r4 to boot.  I may mask it and try an earlier version.

----------

## Bigun

Success!!

 gentoo-sources-2.6.34-r6:  not only did it boot, but I finally got iptables to load.

----------

## d2_racing

Great  :Razz: 

----------

