Ubuntu设置ip地址

来源:互联网 发布:淘宝交易指数在哪里看 编辑:程序博客网 时间:2024/05/18 01:57

$ sudo vi /etc/network/interfaces

auto eth0
iface eth0 inet static
address 192.168.2.1
gateway 192.168.2.254
netmask 255.255.255.0

$ sudo /etc/init.d/networking restart

 

 

原创粉丝点击