1、vi /etc/sysconfig/network
NETWORKING=yes
HOSTNAME=localhost.localdomain
GATEWAY=192.168.110.2
2、vi /etc/resolv.conf
search localdomain
nameserver 192.168.110.2
3、vi /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0
HWADDR=00:0C:29:0D:CE:14
TYPE=Ethernet
UUID=4b598b57-5704-4542-9f71-e00fa214ad31
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=dhcp
IPADDR=192.168.110.12
NETMASK=255.255.255.0
GATEWAY=192.168.110.2
DNS1=192.168.110.2
DNS2=8.8.8.8
时间: 2024-10-08 02:48:13