关于centos7 nat服务的配置
关于centos7 nat服务的配置
首先打开服务里面的nat服务
确认VMnet8已启用,并查看本机ip
虚拟机打开网络编辑器,网关为192.168.78.2
前三步nat虚拟机都适用
切换超级用户:su root
查看网络配置文件:
[[email protected] sha]# cd /etc/sysconfig/network-scripts/
[[email protected] network-scripts]# ls
编辑:vi ifcfg-ens33
可能显示的ip和设置里的不一样,这时重启下服务 service network restart
此时ping本机,ping百度就都ping通了