虚拟机下 centos7 无法连接网络

Posted yanxiatingyu

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了虚拟机下 centos7 无法连接网络相关的知识,希望对你有一定的参考价值。

 

 

 

[[email protected] ~]# cd /etc/sysconfig/network-scripts
[[email protected] network-scripts]# ls
ifcfg-ens33  ifdown-ppp       ifup-ib      ifup-Team
ifcfg-lo     ifdown-routes    ifup-ippp    ifup-TeamPort
ifdown       ifdown-sit       ifup-ipv6    ifup-tunnel
ifdown-bnep  ifdown-Team      ifup-isdn    ifup-wireless
ifdown-eth   ifdown-TeamPort  ifup-plip    init.ipv6-global
ifdown-ib    ifdown-tunnel    ifup-plusb   network-functions
ifdown-ippp  ifup             ifup-post    network-functions-ipv6
ifdown-ipv6  ifup-aliases     ifup-ppp
ifdown-isdn  ifup-bnep        ifup-routes
ifdown-post  ifup-eth         ifup-sit
[[email protected] network-scripts]# vim ifcfg-ens33
[[email protected] network-scripts]# systemctl restart network
[[email protected] network-scripts]# ping www.baidu.com
PING www.a.shifen.com (61.135.169.125) 56(84) bytes of data.
64 bytes from 61.135.169.125 (61.135.169.125): icmp_seq=1 ttl=55 time=25.0 ms
64 bytes from 61.135.169.125 (61.135.169.125): icmp_seq=2 ttl=55 time=25.0 ms
64 bytes from 61.135.169.125 (61.135.169.125): icmp_seq=3 ttl=55 time=25.0 ms
64 bytes from 61.135.169.125 (61.135.169.125): icmp_seq=4 ttl=55 time=25.0 ms
64 bytes from 61.135.169.125 (61.135.169.125): icmp_seq=5 ttl=55 time=24.5 ms
^C
--- www.a.shifen.com ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 13035ms

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

https://blog.csdn.net/rzrenyu/article/details/78469462

 

以上是关于虚拟机下 centos7 无法连接网络的主要内容,如果未能解决你的问题,请参考以下文章

虚拟机下CentOS7网络连接

虚拟机下的Linux连接校园网上网问题

解决虚拟机下安装CentOS无法上网

VMware虚拟机下Centos7 使用桥接方式的配置网路

VMware虚拟机下Centos7 使用桥接方式的配置网路

VMware虚拟机下Centos7 桥接方式网络配置完整步骤