iptables v1.3.5: can't initialize iptables table `nat': Table does not exist (do you need to insmod?) - OpenVZ Container Problem iptables module problem solution

iptables v1.3.5: can't initialize iptables table `nat': Table does not exist (do you need to insmod?)

This solution applies to all other iptables modules/problems for OpenVZ, you'll just need to add them to both lists/lines below if you have modules other than what I have below.

The modules need to be enabled in both iptables and the OpenVZ hostnode itself and then the containers which need it must be restarted.

How To Enable IPTables Modules in OpenVZ

Ensure you have this line by editing /etc/sysconfig/iptables-config

IPTABLES_MODULES="ipt_REDIRECT ipt_REJECT ipt_tos ipt_TOS ipt_LOG ip_conntrack ipt_limit ipt_multiport iptable_filter iptable_mangle ipt_TCPMSS ipt_tcpmss ipt_ttl ipt_length ipt_state iptable_nat ip_nat_ftp"

Edit /etc/sysconfig/vz

IPTABLES="ipt_REDIRECT ipt_REJECT ipt_tos ipt_TOS ipt_LOG ip_conntrack ipt_limit ipt_multiport iptable_filter iptable_mangle ipt_TCPMSS ipt_tcpmss ipt_ttl ipt_length ipt_state iptable_nat ip_nat_ftp"

Enable Them

service restart iptables

You can restart the vz service too but that will take down other containers.  If only one container needs it, just restart the individual container.


Tags:

iptables, initialize, nat, insmod, openvz, container, module, solutioniptables, applies, modules, ll, lists, enabled, hostnode, containers, restarted, enable, ensure, editing, etc, sysconfig, config, iptables_modules, quot, ipt_redirect, ipt_reject, ipt_tos, ipt_log, ip_conntrack, ipt_limit, ipt_multiport, iptable_filter, iptable_mangle, ipt_tcpmss, ipt_ttl, ipt_length, ipt_state, iptable_nat, ip_nat_ftp, edit, vz, restart, individual,

Latest Articles

  • Linux Ubuntu Cannot Print Large Images
  • Cannot Print PDF Solution and Howto Resize
  • Linux Console Login Screen TTY Change Message
  • Apache Cannot Start Listening Already on 0.0.0.0
  • MySQL Bash Query to pipe input directly without using heredoc trick
  • CentOS 6 and 7 / RHEL Persistent DHCP Solution
  • Debian Ubuntu Mint rc-local service startup error solution rc-local.service: Failed at step EXEC spawning /etc/rc.local: Exec format error
  • MySQL Cheatsheet Guide and Tutorial
  • bash script kill whois or other command that is running for too long
  • Linux tftp listens on all interfaces and IPs by DEFAULT Security Risk Hole Solution
  • python import docx error
  • Cisco Unified Communications Manager Express Cheatsheet CUCME CME
  • Linux Ubuntu Debian Missing privilege separation directory: /var/run/sshd
  • bash how to count the number of columns or words in a line
  • bash if statement how to test program output without assigning to variable
  • RTNETLINK answers: Network is unreachable
  • Centos 7 how to save iptables rules like Centos 6
  • nfs tuning maximum amount of connections
  • qemu-kvm error "Could not initialize SDL(No available video device) - exiting"
  • Centos 7 tftpd will not work with selinux enabled