LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Network routing difficulties with 2 NICs (https://www.linuxquestions.org/questions/linux-networking-3/network-routing-difficulties-with-2-nics-4175454120/)

smoyse 03-14-2013 07:13 PM

Network routing difficulties with 2 NICs
 
I am having trouble with routing and two network cards.

My set up is as follows

OS Fedora 17 fully patched.

eth2:
DHCP Fixed IP.
Controlled by NetworkManager
This is the Primary NIC

eth1: -> br0:
DHCP Floating IP
Controlled by network service
This NIC is bridged, and used by a virtual machine.

When my system starts up the routing table looks like this:
Code:

Destination    Gateway        Genmask        Flags Metric Ref    Use Iface
0.0.0.0        10.61.106.30    0.0.0.0        UG    0      0        0 eth2
10.61.106.0    0.0.0.0        255.255.254.0  U    0      0        0 eth2
10.61.106.0    0.0.0.0        255.255.254.0  U    0      0        0 br0
169.254.0.0    0.0.0.0        255.255.0.0    U    1004  0        0 br0
192.168.122.0  0.0.0.0        255.255.255.0  U    0      0        0 virbr0

After disconnecting from a VPN it looks like this
Code:

Destination    Gateway        Genmask        Flags Metric Ref    Use Iface
0.0.0.0        10.61.106.30    0.0.0.0        UG    0      0        0 eth2
10.61.106.0    0.0.0.0        255.255.254.0  U    0      0        0 br0
10.61.106.0    0.0.0.0        255.255.254.0  U    0      0        0 eth2
169.254.0.0    0.0.0.0        255.255.0.0    U    1004  0        0 br0
192.168.122.0  0.0.0.0        255.255.255.0  U    0      0        0 virbr0

At this point I have lost internet connectivity, though I can still connect to the LAN

If I now add a route:route add -net 10.61.106.0/24 eth2, my internet connectivity is restored, and the new routing table looks like so:
Code:

Destination    Gateway        Genmask        Flags Metric Ref    Use Iface
0.0.0.0        10.61.106.30    0.0.0.0        UG    0      0        0 eth2
10.61.106.0    0.0.0.0        255.255.255.0  U    0      0        0 eth2
10.61.106.0    0.0.0.0        255.255.254.0  U    0      0        0 br0
10.61.106.0    0.0.0.0        255.255.254.0  U    0      0        0 eth2
169.254.0.0    0.0.0.0        255.255.0.0    U    1004  0        0 br0
192.168.122.0  0.0.0.0        255.255.255.0  U    0      0        0 virbr0

I have tried everything I can think of to fix this situation, including adding the /24 route in NetworkManager, trying to change the mask of br0 to /22 and setting METRIC in ifcfg-*

I think that this is a bug in NetworkManger, but I don't know if any body has other ideas?

Thanks

Steven

nini09 03-15-2013 03:24 PM

The problem is two duplicate route entry. Why do you do this?
10.61.106.0 0.0.0.0 255.255.254.0 U 0 0 0 eth2
10.61.106.0 0.0.0.0 255.255.254.0 U 0 0 0 br0


All times are GMT -5. The time now is 12:55 AM.