Restarting the network
Tom H
tomh0665 at gmail.com
Wed Mar 3 21:55:18 UTC 2010
>> After my broadband goes down and is then restored, my networking never
>> restores automatically, and the command that Googling leads me to
>> understand
>> should restore it never works:
>> sudo /etc/init.d/networking restart
>> I've also tried
>> ifup eth0
>> and
>> sudo /etc/init.d/network-manager restart
> If eth0 is a wired connection, the first command should restart the
> network cleanly. If its a wired connection, then you should be aware
> that Linux has broken a cardinal rule of UNIX, "all services except the
> kernel should be restartable without reboot". I have yet to be able to
> restart a wireless service without a reboot. I'll be interested to find
> out if anyone else has, and especially, how they did it.
Wired or unwired, if you are using Network Manager with its default settings
sudo invoke-rc.d networking restart
will not have any effect because it uses ifup/ifdown, which will not
work if the NIC is not defined in
/etc/network/interfaces
(hence the "eth0 unknown" message).
The correct command for restarting networking when using Network Manager is
sudo invoke-rc.d network-manager restart
I remember someone posting that she/he brought a network back up after
the above (or invoke-rc.d networking restart when not running Network
Manager) failed by restarting dbus first.
More information about the ubuntu-users
mailing list