Linux设置固定IP教程

发布时间:2017-03-15 02:44

本文为大家介绍Linux设置固定IP教程,欢迎大家阅读。

# vi /etc/sysconfig/network-scripts/ifcfg-eth0

DEVICE=eth0

BOOTPROTO=static

IPADDR=192.168.0.116

NETMASK=255.255.0.0

GATEWAY=192.168.0.1

ONBOOT=yes

TYPE=Ethernet

重启配置文件使之生效

# /etc/init.d/network restart

Shutting down interface eth0: [ OK ]

Shutting down loopback interface: [ OK ]

Setting network parameters: [ OK ]

Bringing up loopback interface: [ OK ]

Bringing up interface eth0: [ OK ]

Linux设置固定IP教程的评论条评论