Skip to content

Latest commit

 

History

History
13 lines (11 loc) · 801 Bytes

iptables.md

File metadata and controls

13 lines (11 loc) · 801 Bytes

启动容器报 iptables: No chain/target/match by that name

  • 重启容器异常

      # docker restart postgresql_2.3.0
      Error response from daemon: Cannot restart container postgresql_2.3.0: driver failed programming external connectivity on endpoint postgresql_2.3.0 (8d2ed2323441360526edf348f79154a338736e2397c392546b166f0bd6e74509):  (iptables failed: iptables --wait -t nat -A DOCKER -p tcp -d 0/0 --dport 5437 -j DNAT --to-destination 172.25.3.8:5432 ! -i br-a6e9dca84530: iptables: No chain/target/match by that name.
       (exit status 1))
    
  • 原因分析

    • 启动docker service的时候,防火墙是关闭状态,那么docker管理网络时就不会操作网管的配置(chain docker)。

    • 解决办法,重启docker。

        service docker restart
        或 
        systemctl restart docker