Daily Ubuntu / Linux news and application reviews.


Many network problems in Ubuntu or Kubuntu seem to be related to the network manager not working correctly so here is how to configure your wired network manually:

1. The first thing we need to do is remove the network-manager:

-for Ubuntu:
sudo apt-get remove network-manager-gnome network-manager
-for Kubuntu:
sudo apt-get remove network-manager-kde network-manager

2. Now, type this in a terminal:
to see your active interfaces. Hopefully you will see at least eth0 and lo listed. If not, you need to get eth0 working, and that is beyond the scope of this howto.

3. The next step is to manually set up the /etc/network/interfaces file. Open it by typing the following command in a terminal:

-for Ubuntu:
gksu gedit /etc/network/interfaces
-for Kubuntu:
kdesu kate /etc/network/interfaces

A. For a static IP, the file needs to look like this:
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
Obviously, change eth0, address and gateway to your values.

For a static IP, before you get connected we need to tell your computer where to find the domain name servers (DNS). That is the function of the /etc/resolv.conf file so you need to edit this file. If it doesn't exist, create it.

-For Ubuntu:
gksu gedit /etc/resolv.conf
-For Kubuntu:
kdesu kate /etc/resolv.conf

And enter your domain name servers (DNS) like this:
Obviously, replace the above values with your DNS values.

Please note that you can have up to three nameservers listed in resolv.conf

B. Using DHCP
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet dhcp

C. For a PPPOE connection:
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet manual

auto dsl-provider
iface dsl-provider inet ppp
pre-up /sbin/ifconfig eth0 up # line maintained by pppoeconf
provider dsl-provider

And then run pppoeconf in a terminal, click ok to everything, enter username and password, etc.

4. Now let's test and see if everything worked ok:
sudo /etc/init.d/networking restart

Please feel free to point out any mistakes or other helpful hints.
Newer Post
Older Post