새소식

⇥ DevOps Tech 🙋🏻‍♀️/✏️ Cloud

[docker] iptables failed - No chain/target/match by that name

  • -
반응형

도커 데몬이 부팅되있는 상태로 로컬 장비의 방화벽 설정을 수정했을 때 발생하는 에러이다.

# docker run -itd --name mydb2 --privileged=true -p 50000:50000 -e LICENSE=accept -e DB2INST1_PASSWORD=1215 -e DBNAME=tibero -v /jw/db2:/database ibmcom/db2
2ddd8a9b2d8c07ab8b318038d0a49747e87e17e25211eb479229f668f2797d17
docker: Error response from daemon: driver failed programming external connectivity on endpoint mydb2 (ce1d2c8baa700ec48555fb0b70767c3747ed09ae0a06a5bd15655c3581fb80f9):  (iptables failed: iptables --wait -t nat -A DOCKER -p tcp -d 0/0 --dport 50000 -j DNAT --to-destination 172.17.0.2:50000 ! -i docker0: iptables: No chain/target/match by that name.
 (exit status 1)).

 

아래의 명령어로 네트워크 수정 후 도커를 재시작해주면 된다.

#  --flush   -F [chain]          Delete all rules in  chain or all chains
sudo iptables -t filter -F  

# --table       -t table        table to manipulate (default: `filter')
sudo iptables -t filter -X 

systemctl restart docker
반응형
Contents

포스팅 주소를 복사했습니다

이 글이 도움이 되었다면 공감 부탁드립니다.