Saturday, June 03, 2017

Question about p2p OpenVPN interfaces

Hi,

I'm currently experimenting to run OpenBGPD over OpenVPN p2p links (not
the common /30 or /31 interconnection network we can see on Internet).
It works great for the BGP part, but the exported routes to the kernel
does not correspond to the BGP ones.

For exemple, if I look for the route to 172.23.0.53, it should goes
via 172.22.141.148 according to BGPD:
# bgpctl show rib 172.23.0.53
flags: * = Valid, > = Selected, I = via IBGP, A = Announced, S = Stale
origin: i = IGP, e = EGP, ? = Incomplete

flags destination gateway lpref med aspath origin
*> 172.23.0.48/28 172.22.141.148 100 0 64737 i
* 172.23.0.48/28 172.23.67.1 100 0 4242420022 i
* 172.23.0.48/28 172.20.31.252 100 0 4242423957 64737 i
* 172.23.0.48/28 172.20.190.129 100 0 4242423759 4242420022 i
* 172.23.0.48/28 172.22.159.239 100 0 4242420812 4242420022 i

But if I do the same query on the kernel table, the route is set
thought tun3:
# route get 172.23.0.53
route to: 172.23.0.53
destination: 172.23.0.48
mask: 255.255.255.240
gateway: 172.23.135.129
interface: tun3
if address: 172.23.135.129
priority: 48 (bgp)
flags: <UP,GATEWAY,DONE>
use mtu expire
463 0 0
# ifconfig tun3
tun3: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
index 8 priority 0 llprio 3
groups: tun
status: active
inet 172.23.135.129 --> 172.20.44.1 netmask 0xffffffff
inet6 fe80::8db:5e3f:eb64:fb57%tun3 -> prefixlen 64 scopeid 0x8
inet6 fd40:9dc7:b528:1::2 -> prefixlen 64

But, 172.22.141.148 (the BGP gateway) is on tun1:
# ifconfig tun1
tun1: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
index 23 priority 0 llprio 3
groups: tun
status: active
inet 172.23.135.129 --> 172.22.141.148 netmask 0xffffffff
inet6 fe80::8db:5e3f:eb64:fb57%tun1 -> prefixlen 64 scopeid 0x17
inet6 fd40:9dc7:b528:35::1:1 -> prefixlen 112

Am I missing something obvious or is it a bug?

Thanks for your help,
--
alarig

No comments:

Post a Comment