CentOS7静态IP设置

[root@localhost network-scripts]# pwd
/etc/sysconfig/network-scripts

[root@localhost network-scripts]# cat ifcfg-enp0s3
TYPE=Ethernet
BOOTPROTO=static
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=no
IPV6_AUTOCONF=no
IPV6_DEFROUTE=no
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=enp0s3
UUID=4fea9152-58f4-44bd-9c58-dcaea702b029
DEVICE=enp0s3
ONBOOT=yes
IPV6_PEERDNS=no
IPV6_PEERROUTES=no
PEERDNS=yes
PEERROUTES=yes
DNS1=180.76.76.76
IPADDR=192.168.10.136
PREFIX=24
GATEWAY=192.168.10.1

  

posted @ 2017-05-11 16:32  庚武  Views(178)  Comments(0Edit  收藏  举报