Results 1 to 6 of 6

Thread: Network manager, /etc/network/interfaces

  1. #1
    Join Date
    Jan 2013
    Beans
    18

    Network manager, /etc/network/interfaces

    I have been experimenting with the interfaces file to tweak my connection. It just wasn't a good connection before and now it is great. I added the following to the file
    auto lo
    iface lo inet loopback
    dns-nameservers 8.8.8.8 8.8.4.4

    however have to use dhclient to get the connection working really well, found this and was thinking about adding it
    auto eth0
    iface eth0 inet dhcp

    don't know if that will work. My real question is, what are these commands? Would it be something written in python? Or some other commands? I am trying to research it but there is nothing out there about this. What kind of script it it?
    Last edited by Cthulu2156; January 24th, 2013 at 01:02 AM.

  2. #2
    Join Date
    Feb 2007
    Location
    West Hills CA
    Beans
    10,049
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: Network manager, /etc/network/interfaces

    Code:
    man interfaces
    Depending on what desktop environment you are running, there are graphical user interfaces (gui's) to change them. Look in your Control Panel.

    From a Dapper Drake machine with static address:

    tgalati4@tubuntu2:~$ cat /etc/network/interfaces
    # This file describes the network interfaces available on your system
    # and how to activate them. For more information, see interfaces(5).

    # The loopback network interface
    auto lo
    iface lo inet loopback

    # This is a list of hotpluggable network interfaces.
    # They will be activated automatically by the hotplug subsystem.
    auto eth0

    # The primary network interface
    iface eth0 inet static
    address 192.168.1.114
    netmask 255.255.255.0
    gateway 192.168.1.1

    And in Quantal Quetzal: (with dhcp)

    # interfaces(5) file used by ifup(8) and ifdown(8)
    auto lo
    iface lo inet loopback

    Code:
    man ifup
    Last edited by tgalati4; January 24th, 2013 at 12:28 AM.
    -------------------------------------
    Oooh Shiny: PopularPages

    Unumquodque potest reparantur. Patientia sit virtus.

  3. #3
    Join Date
    Jan 2013
    Beans
    18

    Re: Network manager, /etc/network/interfaces

    That helps a lot, thanks. I was not aware of a man page for interfaces, there are a ton of files, and I honestly can't even remember how I found the interfaces file.
    Last edited by Cthulu2156; January 24th, 2013 at 01:20 AM.

  4. #4
    Join Date
    Apr 2012
    Beans
    6,930

    Re: Network manager, /etc/network/interfaces

    Just a word of caution - newer desktop editions of Ubuntu use a whole different service (network-manager) which is configured via the GUI applet (and uses config files in /etc/NetworkManager) - that's why the default /etc/network/interfaces file only contains a definition for the loopback (lo) interface.

    If you want to manually set DNS servers for a connection that's managed by network-manager, then the right place to do that is to edit the connection via the applet and change the IPv4 settings from 'Automatic (DHCP)' to 'Automatic (DHCP) addresses only' and then input your DNS server IP(s) in the box(es) provided

  5. #5
    Join Date
    Jan 2013
    Beans
    18

    Re: Network manager, /etc/network/interfaces

    I did try that, but there was no change in my connection, the only thing that made the connection better was by adding the DNS info to the interfaces file, but then I still had to start the dhclient which was in another thread, I know the dhcp should be working with what is already in the interfaces file, but for some reason worked better when I used dhclient, I'm not sure why it is better but it's much faster now. This is what I have in my interfaces file

    auto lo
    iface lo inet loopback
    dns-nameservers 8.8.8.8 8.8.4.4
    auto eth0
    iface eth0 inet dhcp

    which I'm guessing just gets dhcp working with the dns nameservers i am using

  6. #6
    Join Date
    Feb 2007
    Location
    West Hills CA
    Beans
    10,049
    Distro
    Ubuntu 14.04 Trusty Tahr

    Re: Network manager, /etc/network/interfaces

    Interfaces is a legacy configuration file used in the "old days" of linux. However, I believe it is still used for server installs and lightweight distros. So just be mindful that network configuration is slightly different for each distro.

    Also realize that dhcp is a client-server process. If the server (a router that hands out IP addresses) is having issues then you will have issues on your machine (the dhcp client). Without knowing anything about your dhcp server, it's hard to troubleshoot this issue.
    -------------------------------------
    Oooh Shiny: PopularPages

    Unumquodque potest reparantur. Patientia sit virtus.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •