想给我的ubuntu 8.10设一个静态IP ,按照网上给的步骤设了,但重启网络后无法上网,一番搜索后找到了答案,要先删除networkmanager。然后就一切顺利了。
详细的步骤在
http://www.linuxeye.cn/2008/11/28/ubuntu-810%E7%BD%91%E7%BB%9C%E9%85%8D%E7%BD%AE%E5%8E%86%E7%A8%8B/
其中提到了重启网络的方法,比较麻烦,我在其他网页上看到有更简单的。
sudo /etc/init.d/networking restart
附上/etc/network/interfaces内容:
***************************
auto lo
iface lo inet loopback
# The primary network interface
#auto eth0
#iface eth0 inet static
#iface eth0 inet dhcp
#address 192.168.1.155
#netmask 255.255.255.0
#gateway 192.168.1.1
auto dsl-provider
iface dsl-provider inet ppp
pre-up /sbin/ifconfig eth0 up # line maintained by pppoeconf
provider dsl-provider
auto eth0
iface eth0 inet static
address 192.168.1.155
netmask 255.255.255.0
gateway 192.168.1.1