Gottfried Szing wrote:



David wrote:

I'm just building a brand new Ubuntu server box. Unfortunately I put in the wrong address for the nameserver so I changed it manually (edited /etc/resolv.conf and /etc/network/interfaces) and now if I restart networking I lose the eth0 connection completely! ie, ifconfig only shows loopback.

If I completely reboot the machine, eth0 comes back and works fine until the next time I restart networking :(

Can anyone suggest what I'm doing wrong?


disclaimer: AFAIK is ubuntu very similar to debian, so this suggestions might not work if the differences between debian and ubuntu are to big.

the network scripts utilizes the commands ifup and ifdown (located in /sbin). so you can try to call the commands ifup/ifdown directly and to turn on the verbose-mode.

e.g. as root

$ ifdown -v eth0
$ ifup -v eth0


Also these 'ifdown' and 'ifup' scripts take the ff file as parameter:

'ifcfg-eth0'   and so you must ensure the contents are in order.

For example,

DEVICE=eth0
BOOTPROTO=static
BROADCAST=192.168.1.255
IPADDR=192.168.1.254
NETMASK=255.255.255.0
NETWORK=192.168.1.0
ONBOOT=yes
TYPE=Ethernet

because the network-script does more than just bringing up the interfaces, you could also run the network script in debug mode and check the output for possible error messages.

$ bash -x /etc/init.d/network restart

hth, gottfried


--
SLUG - Sydney Linux User's Group Mailing List - http://slug.org.au/
Subscription info and FAQs: http://slug.org.au/faq/mailinglists.html

Reply via email to