Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Ubuntu User (http://www.linux-archive.org/ubuntu-user/)
-   -   what is the correct way to restart network on the command line (http://www.linux-archive.org/ubuntu-user/581694-what-correct-way-restart-network-command-line.html)

Wes James 09-29-2011 04:43 PM

what is the correct way to restart network on the command line
 
I've tried:

sudo /etc/init.d/networking restart

but get a deprecation error

I googled this and it seems to have changed to:

sudo ifdown eth0
sudo ifup eth0

but when I do that I get "interface eth0 not configured"

I look in:

/etc/network/interfaces

and all it has is:

auto lo
iface lo inet loopback

no eth0?

where can I study up on networking on 11.04?

The indicator in the Gnome menu bar can disconnect/reconnect
connections or turn networking off or on - is it using scripts to do
this work?

Thanks,

-wes

--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users

Verde Denim 09-29-2011 04:54 PM

what is the correct way to restart network on the command line
 
On Thu, Sep 29, 2011 at 12:43 PM, Wes James <comptekki@gmail.com> wrote:

I've tried:



sudo /etc/init.d/networking restart



but get a deprecation error



I googled this and it seems to have changed to:



sudo ifdown eth0

sudo ifup eth0



but when I do that I get "interface eth0 not configured"



I look in:



/etc/network/interfaces



and all it has is:



auto lo

iface lo inet loopback



no eth0?



where can I study up on networking on 11.04?



The indicator in the Gnome menu bar can disconnect/reconnect

connections or turn networking off or on - is it using scripts to do

this work?



Thanks,



-wes


Wes
There seems to be some discrepancy in the way this has been automated in various releases. network-manager is supposed to work, but doesn't always. It sounds from the description of your interfaces file that network-manager is what you have been using. If you drop into a terminal and run (as sudo):

killall nm-applet and then nm-applet --sm-disable
what is the result?

If your default device is indeed eth0 (and not something else), you should see it - unless the nm-appliet has gone awry again (as it has on my systems numerous times).


If you're using ip addressing, you can always add the appropriate info to the /etc/networking/interfaces file yourself.

If you're acquiring the address dynamically (a la dhcp), there is a client that you can run - dhcp3 iirc, that should lease an address for you.


Other more knowledgeable than I will likely have more specific advise, but this should get you a starting point.

Regards

Jack


--

ubuntu-users mailing list

ubuntu-users@lists.ubuntu.com

Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users



--
ubuntu-users mailing list
ubuntu-users@lists.ubuntu.com
Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-users


All times are GMT. The time now is 03:50 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.