linux网络配通

Linux网络配置:

vim /etc/sysconfig/network-scripts/ifcfg-ens33

ONBOOT="yes"

DNS=8.8.8.8

IPADDR=192.168.118.90

NETMASK=255.255.255.0

GATEWAY=192.168.118.2

BOOTPROTO="static"

vim /etc/resolv.conf

nameserver 8.8.8.8

systemctl restart network

ping baidu.com