LINUX/UBUNTU下如何設(shè)置固定IP地址 (轉(zhuǎn))驗(yàn)證有效
運(yùn)行如下命令:
$ sudo vi /etc/network/interfaces
修改auto eth0下的相關(guān)內(nèi)容為如下:
auto eth0運(yùn)行如下命令重啟網(wǎng)絡(luò)服務(wù):
#iface eth0 inet dhcp -- 這個(gè)是自動(dòng)ip的設(shè)置
iface eth0 inet static
address [ip地址]
netmask [子網(wǎng)掩碼]
gateway [網(wǎng)關(guān)]
$ sudo /etc/init.d/networking restart
我是reboot之后才生效
轉(zhuǎn)自:http://blog.163.com/lgh_2002/blog/static/440175262013526113335331/
我是reboot之后才生效
轉(zhuǎn)自:http://blog.163.com/lgh_2002/blog/static/440175262013526113335331/
posted on 2014-03-26 16:18 小秦 閱讀(248) 評(píng)論(0) 編輯 收藏