虚拟机ping不通问题排查

刚开始ifconfig没有ip地址,解决:
cd /etc/sysconfig/network-scripts/
ls --查看文件夹下目录
vi ifcfg-xx
image
service network restart 重启网络
systemctl status network.service 查看网络状态
出现错误:Job for network.service failed because the control process exited with error code
解决方法参考:Job for network.service failed because the control process exited with error code
浅谈linux虚拟机没有ip的问题
网络启动后还是ping不通,考虑防火墙:
systemctl stop firewalld.service #停止firewall
systemctl disable firewalld.service #禁止firewall开机启动
参考文章 : 虚拟机ping不通的几种常见解决方法
能ping通同网段的主机,ping不通不同网段的主机
解决犯法:
route -n发现没有默认路由
解决方法参考:
Linux 不同网段两台主机相互ping通
至此问题解决

posted @ 2021-12-22 10:57  花满园  阅读(466)  评论(0编辑  收藏  举报