[FROG] how to get routing table entries with different src ip / from dummy interface?

Stefan Priebe - Profihost AG s.priebe at profihost.ag
Tue Sep 17 03:13:12 EDT 2019


Hi Jan,

Am 17.09.19 um 09:00 schrieb Jan Marquardt:
> Hi Stefan,
> 
> as far as I remember I had a similar issue some time ago which
> I solved by adding the addresses to lo instead of dummyN.

yes i saw your issue but was not able to solve mine with the notes in
the bug report.

If i move my IP from dummy0 to lo i do not even get a successful bgp
connection.

What i tried:

# ip a l dev lo
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN
group default qlen 1
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet 37.228.152.3/32 scope global lo
       valid_lft forever preferred_lft forever
    inet6 fe80::200:ff:fe00:0/64 scope link
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever

so ip is bound to lo.

frr.conf:
 neighbor internal-bgp update-source 37.228.152.3
 neighbor 37.228.152.2 peer-group internal-bgp


but:
# show ip bgp sum
...
37.228.152.2    4      34432       0       0        0    0    0    never
     Connect
...

So it always stays just in connect mode and never connects.

This most probably happens because a connection is not possible from lo:
# ping -I lo 37.228.152.2
PING 37.228.152.2 (37.228.152.2) from 37.228.152.3 lo: 56(84) bytes of data.

The route to 37.228.152.2 is set up like this:
# route -n | grep 37.228.152.2
37.228.152.2    192.0.2.2       255.255.255.255 UGH   20     0        0 br99

Stefan

> 
> Best Regards
> 
> Jan
> 
>> Am 17.09.2019 um 08:48 schrieb Stefan Priebe - Profihost AG <s.priebe at profihost.ag>:
>>
>> Hello list,
>>
>> i'm trying to get an linux kernel routing table entry like this one:
>> # ip r get 52.218.237.186
>> 52.218.237.186 via 192.0.2.2 dev br99 src 37.228.152.3
>>
>> but frr always creates entries like this one:
>> # ip r get 52.218.237.186
>> 52.218.237.186 via 192.0.2.2 dev br99 src 192.0.2.3
>>
>> 37.228.152.3 is an ip of an dummy0 interface and 192.0.2.3 is the ip of
>> br99.
>>
>> frr.conf:
>>
>> router bgp XXXXX
>> bgp router-id 37.228.152.3
>> neighbor internal-bgp peer-group
>> neighbor internal-bgp remote-as XXXXX
>> neighbor internal-bgp capability dynamic
>> neighbor 37.228.152.2 peer-group internal-bgp
>> neighbor 37.228.152.2 description R2
>> neighbor 37.228.152.2 update-source dummy0
>> !
>> address-family ipv4 unicast
>>  neighbor 37.228.152.2 next-hop-self
>> exit-address-family
>> !
>>
>> Greets,
>> Stefan
>>
>> _______________________________________________
>> frog mailing list
>> frog at lists.frrouting.org
>> https://lists.frrouting.org/listinfo/frog
> 



More information about the frog mailing list