Community discussions

 
dannyleroux
just joined
Topic Author
Posts: 3
Joined: Sun Mar 25, 2018 3:22 pm
Location: South Africa
Contact:

OSPF with VRF

Sun Mar 25, 2018 5:05 pm

Good day, guys.

I need help with the following issue I am experiencing. I am trying to establish an OSPF adjacency between my CE (client edge) and PE (provider edge) with VRF set up on my PE.
The adjacency establishes fine when disabling the VRF as connectivity between the two devices is perfect without any routing marks.
When enabling the VRFs though, the adjacency terminates.

Please find below PE and CE configurations:

PE (R1-PE):
/ip address
add address=1.1.1.1 interface=loopback network=1.1.1.1
add address=10.14.0.1/24 interface=ether1 network=10.14.0.0
add address=192.168.34.200/24 interface=ether5 network=192.168.34.0
add address=172.16.101.1/30 interface=ether2 network=172.16.101.0

/ip route print detail
0 ADC dst-address=172.16.101.0/30 pref-src=172.16.101.1 gateway=ether2 gateway-status=ether2 reachable distance=0 scope=10 routing-mark=101:ASH
1 A S dst-address=0.0.0.0/0 gateway=192.168.34.1 gateway-status=192.168.34.1 reachable via ether5 distance=1 scope=30 target-scope=10
2 ADC dst-address=1.1.1.1/32 pref-src=1.1.1.1 gateway=loopback gateway-status=loopback reachable distance=0 scope=10
3 ADo dst-address=2.2.2.2/32 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=20 ospf-type=intra-area
4 ADo dst-address=3.3.3.3/32 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=30 ospf-type=intra-area
5 ADo dst-address=4.4.4.4/32 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=40 ospf-type=intra-area
6 ADo dst-address=5.5.5.5/32 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=50 ospf-type=intra-area
7 ADC dst-address=10.14.0.0/24 pref-src=10.14.0.1 gateway=ether1 gateway-status=ether1 reachable distance=0 scope=10
8 ADo dst-address=10.23.0.0/24 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=20 ospf-type=intra-area
9 ADo dst-address=10.34.0.0/24 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=30 ospf-type=intra-area
10 ADo dst-address=10.45.0.0/24 gateway=10.14.0.2 gateway-status=10.14.0.2 reachable via ether1 distance=110 scope=20 target-scope=10 ospf-metric=40 ospf-type=intra-area
11 ADC dst-address=192.168.34.0/24 pref-src=192.168.34.200 gateway=ether5 gateway-status=ether5 reachable distance=0 scope=10

/routing bgp instance
add as=65531 client-to-client-reflection=no name=mBGP router-id=1.1.1.1
/routing bgp instance vrf
add instance=mBGP redistribute-ospf=yes redistribute-other-bgp=yes redistribute-rip=yes routing-mark=101:ASH
add instance=mBGP redistribute-ospf=yes redistribute-other-bgp=yes redistribute-rip=yes routing-mark=102:Beat
/routing bgp peer
add address-families=ip,vpnv4 instance=mBGP name=peer1 remote-address=5.5.5.5 remote-as=65531 ttl=default update-source=loopback

/ip route vrf print detail
0 routing-mark=101:ASH interfaces=ether2 route-distinguisher=1.1.1.1:1 import-route-targets=5.5.5.5:101 export-route-targets=1.1.1.1:101
1 routing-mark=102:Beat interfaces=ether3 route-distinguisher=1.1.1.1:2 import-route-targets=5.5.5.5:102 export-route-targets=1.1.1.1:102

CE (R6-CE):
/ip address
add address=172.16.0.2/12 interface=ether2 network=172.16.0.0
add address=10.10.10.10 interface=loopback network=10.10.10.10
add address=172.16.101.2/30 interface=ether2 network=172.16.101.0

/routing ospf network print detail
0 network=172.16.101.0/30 area=backbone
1 network=10.10.10.10/32 area=backbone

/ip route print detail
0 ADC dst-address=10.10.10.10/32 pref-src=10.10.10.10 gateway=loopback gateway-status=loopback reachable
distance=0 scope=10

1 ADC dst-address=172.16.0.0/12 pref-src=172.16.0.2 gateway=ether2 gateway-status=ether2 reachable
distance=0 scope=10

2 ADC dst-address=172.16.101.0/30 pref-src=172.16.101.2 gateway=ether2 gateway-status=ether2 reachable
distance=0 scope=10





Please let me know if you guys need more details?
I understand that I can use other routing protocols, I need to understand why this doesn't work and not just move on. Please supply suggestions or advise.

Thanks.
You do not have the required permissions to view the files attached to this post.
 
Vooray
Frequent Visitor
Frequent Visitor
Posts: 68
Joined: Mon Feb 23, 2015 3:34 pm

Re: OSPF with VRF

Mon Mar 26, 2018 1:31 pm

Try get some logs
/system logging add topics=ospf,!raw
And please, paste configs with code formated
 
dannyleroux
just joined
Topic Author
Posts: 3
Joined: Sun Mar 25, 2018 3:22 pm
Location: South Africa
Contact:

Re: OSPF with VRF

Mon Mar 26, 2018 3:57 pm

Hi,

Thanks for the reply, apologies about the "code format" not really sure which format I should use? First post.

Regards
 
dannyleroux
just joined
Topic Author
Posts: 3
Joined: Sun Mar 25, 2018 3:22 pm
Location: South Africa
Contact:

Re: OSPF with VRF

Mon Mar 26, 2018 4:17 pm

Hi,

Please find below log on PE:

Code: Select all

[admin@R1-PE] /log> print follow
mar/25 14:33:26 system,error,critical router was rebooted without proper shutdown
mar/25 14:33:46 route,bgp,warning Update source: interface loopback has no suitable addresses, ignoring it
mar/25 14:33:46 route,bgp,info Failed to open TCP connection: Network is unreachable
mar/25 14:33:46 route,bgp,info RemoteAddress=5.5.5.5
mar/25 14:33:46 interface,info ether1 link up
mar/25 14:33:46 interface,info ether2 link up
mar/25 14:33:46 interface,info ether3 link up
mar/25 14:33:46 interface,info ether4 link up
mar/25 14:33:46 interface,info ether5 link up
mar/25 14:33:51 system,info,account user admin logged in via local
mar/25 14:34:36 route,bgp,info Failed to open TCP connection: No route to host
mar/25 14:34:36 route,bgp,info RemoteAddress=5.5.5.5
mar/25 14:34:56 route,bgp,info TCP connection established
mar/25 14:34:56 route,bgp,info RemoteAddress=5.5.5.5
mar/25 15:43:03 system,info address added by admin
mar/25 15:44:46 system,info OSPFv2 network added by admin
mar/25 15:46:36 system,error,critical login failure for user admin from 192.168.34.254 via winbox
mar/25 15:46:40 system,info,account user admin logged in from 192.168.34.254 via winbox
mar/25 15:47:14 system,info address removed by admin
mar/25 15:47:16 system,info address removed by admin
mar/25 15:47:28 system,info bgp instance vrf changed by admin
mar/25 15:47:32 system,info bgp instance vrf changed by admin
mar/25 15:48:35 system,info,account user admin logged in from 192.168.34.254 via telnet
15:00:48 system,info log rule added by admin
15:00:48 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:00:57 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:00:57 route,ospf,debug received options: E
15:00:58 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:01:07 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:01:07 route,ospf,debug received options: E
15:01:08 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:01:17 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:01:17 route,ospf,debug received options: E
15:01:18 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:01:27 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:01:27 route,ospf,debug received options: E
15:01:28 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:01:37 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:01:37 route,ospf,debug received options: E
15:01:38 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:01:47 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:01:47 route,ospf,debug received options: E
15:01:48 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:01:57 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:01:57 route,ospf,debug received options: E
15:01:58 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:02:07 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:02:07 route,ospf,debug received options: E
15:02:08 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:02:17 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:02:17 route,ospf,debug received options: E
15:02:18 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:02:27 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:02:27 route,ospf,debug received options: E
15:02:28 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:02:37 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:02:37 route,ospf,debug received options: E
15:02:38 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:02:47 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:02:47 route,ospf,debug received options: E
15:02:48 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
15:02:57 route,ospf,debug RECV: Hello <- 10.14.0.2 on ether1 (10.14.0.1)
15:02:57 route,ospf,debug received options: E
15:02:58 route,ospf,debug SEND: Hello 10.14.0.1 -> 224.0.0.5 on ether1
-- Ctrl-C to quit. Space prints separator. New entries will appear at bottom.

And the CE:

Code: Select all

[admin@ASH_CE1] > log print follow
mar/25 14:33:24 system,error,critical router was rebooted without proper shutdown
mar/25 14:33:43 interface,info ether1 link up
mar/25 14:33:43 interface,info ether2 link up
mar/25 14:33:43 interface,info ether3 link up
mar/25 14:33:43 interface,info ether4 link up
mar/25 14:33:43 interface,info ether5 link up
mar/25 14:34:28 system,info,account user admin logged in via local
mar/25 15:41:11 system,info device added by admin
mar/25 15:41:34 system,info address added by admin
mar/25 15:43:26 system,info address added by admin
mar/25 15:43:53 system,info OSPFv2 network added by admin
mar/25 15:44:28 system,info OSPFv2 network added by admin
15:02:20 system,info log rule added by admin
15:02:25 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:02:35 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:02:45 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:02:55 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:03:05 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:03:15 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:03:25 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:03:35 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:03:45 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:03:55 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:04:05 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:04:15 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:04:25 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:04:35 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:04:45 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:04:55 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:05:05 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:05:15 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:05:25 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:05:35 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:05:45 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:05:55 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:06:05 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:06:15 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:06:25 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
15:06:35 route,ospf,debug SEND: Hello 172.16.101.2 -> 224.0.0.5 on ether2
-- Ctrl-C to quit. Space prints separator. New entries will appear at bottom.
So by the looks of it, it doesn't seem like a Hello is being sent to the CE?
Also, when adding 172.16.101.0/30 to /routing ospf network, the interface isn't dynamically added like the rest of the networks I've added?

Code: Select all

[admin@R1-PE] /routing ospf interface> print
Flags: X - disabled, I - inactive, D - dynamic, P - passive
# INTERFACE COST PRIORITY NETWORK-TYPE AUTHENTICATION AUTHENTICA
0 DP loopback 10 1 broadcast none
1 D ether1 10 1 broadcast none
Please let me know if you need additional information.

Thanks.
 
Vooray
Frequent Visitor
Frequent Visitor
Posts: 68
Joined: Mon Feb 23, 2015 3:34 pm

Re: OSPF with VRF

Mon Mar 26, 2018 5:11 pm

Interface should be dynamically added if you created corresponding ospf network.
You created separate ospf instance for this ipvpn, right?

Who is online

Users browsing this forum: No registered users and 8 guests