概述
因为开发需求,需要基于银河麒麟V10 SP1构建一个Docker容器用于做开发环境,在测试的过程中,遇到部分问题,该文章用作记录
Q1:Docker容器内的SSHD 服务程序异常,连接时间比较长,docker启动容器的时候,提示
WARNING: IPv4 forwarding is disabled. Networking will not work
A:解决方案如下
1.vim /etc/sysctl.conf #打开文件sysctl.conf
2.net.ipv4.ip_forward=1 #添加net.ipv4.ip_forward=1
3.systemctl restart network #重制网络或者sysctl -p