Results 1 to 6 of 6

Thread: Setting up multiple networking interfaces

  1. #1
    Join Date
    Jun 2009
    Beans
    10
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Unhappy Setting up multiple networking interfaces

    I'm running into issues when I set up multiple networking interfaces. I have 2 interfaces one a public IP and the other one a private one. I set them up as shown below in the /etc/networking/interfaces.

    Code:
    # The loopback network interface
    auto lo
    iface lo inet loopback
    
    # The PUBLIC primary network interface
    auto eth0
    iface eth0 inet static
    address 199.x.x.x
    netmask 255.255.255.0
    gateway 199.x.x.x
    
    # The PRIVATE second network interface
    auto eth1
    iface eth1 inet static
    address 192.168.x.x
    netmask 255.255.255.0
    gateway 192.168.x.x
    The issue is, when both ethernet cables are plugged in, I'm unable to connect to the server through the Public network. When I unplug the second(PRIVATE) network, I'm able to connect. Is there something wrong with my configuration? Thanks.

  2. #2
    Join Date
    Jan 2006
    Location
    Not heaven... Iowa
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Setting up multiple networking interfaces

    Might be an issue with gateway settings - what is shown in route -n - both with and without eth1.
    Linux User #415691 Ubuntu User #8629
    Iowa Team (LoCo): [Wiki] [Launchpad]
    IRC channel: #ubuntu-us-ia on irc.freenode.net

  3. #3
    Join Date
    Jun 2009
    Beans
    10
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Setting up multiple networking interfaces

    here's route -n with eth1:

    Code:
    Kernel IP routing table
    Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
    199.x.x.0    0.0.0.0         255.255.255.0   U     0      0        0 eth0
    192.x.x.0   0.0.0.0         255.255.255.0   U     0      0        0 eth1
    0.0.0.0         192.x.x.1   0.0.0.0         UG    100    0        0 eth1
    0.0.0.0         199.x.x.1    0.0.0.0         UG    100    0        0 eth0
    and without eth1:
    Code:
    Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
    199.x.x.0    0.0.0.0         255.255.255.0   U     0      0        0 eth0
    0.0.0.0         199.x.x.1    0.0.0.0         UG    100    0        0 eth0
    Thanks again for your help.

    Quote Originally Posted by Iowan View Post
    Might be an issue with gateway settings - what is shown in route -n - both with and without eth1.

  4. #4
    Join Date
    Jun 2009
    Beans
    10
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: Setting up multiple networking interfaces

    Can someone please help me with this?

    Quote Originally Posted by cyrusthevirus View Post
    I'm running into issues when I set up multiple networking interfaces. I have 2 interfaces one a public IP and the other one a private one. I set them up as shown below in the /etc/networking/interfaces.

    Code:
    # The loopback network interface
    auto lo
    iface lo inet loopback
    
    # The PUBLIC primary network interface
    auto eth0
    iface eth0 inet static
    address 199.x.x.x
    netmask 255.255.255.0
    gateway 199.x.x.x
    
    # The PRIVATE second network interface
    auto eth1
    iface eth1 inet static
    address 192.168.x.x
    netmask 255.255.255.0
    gateway 192.168.x.x
    The issue is, when both ethernet cables are plugged in, I'm unable to connect to the server through the Public network. When I unplug the second(PRIVATE) network, I'm able to connect. Is there something wrong with my configuration? Thanks.

  5. #5
    Join Date
    Jan 2006
    Location
    Not heaven... Iowa
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Setting up multiple networking interfaces

    Try commenting out the gateway setting for eth1, and restart networking
    (sudo /etc/init.d/networking restart)
    Linux User #415691 Ubuntu User #8629
    Iowa Team (LoCo): [Wiki] [Launchpad]
    IRC channel: #ubuntu-us-ia on irc.freenode.net

  6. #6
    Join Date
    Jun 2009
    Beans
    10
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: [Solved]Setting up multiple networking interfaces

    Just wanted to say thanks. Commenting out the second gateway worked.

    Quote Originally Posted by Iowan View Post
    Try commenting out the gateway setting for eth1, and restart networking
    (sudo /etc/init.d/networking restart)

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
  •