docker WARNING: IPv4 forwarding is disabled. Networking will not work.
CentOS7.1
. 运行某镜像时,报WARNING: IPv4 forwarding is disabled. Networking will not work.
docker run -it 94e814e2efa8 bash
. 解决方法
echo net.ipv4.ip_forward=1 >> /usr/lib/sysctl.d/00-system.conf
systemctl restart network && systemctl restart network
再执行1的命令就不报错了.
本文来自博客园,作者:三百里江山,转载请注明原文链接:https://www.cnblogs.com/300js/p/10903285.html