{"id":535,"date":"2020-07-13T04:47:26","date_gmt":"2020-07-13T04:47:26","guid":{"rendered":"https:\/\/technobabble.us.to\/?page_id=535"},"modified":"2020-12-17T05:25:40","modified_gmt":"2020-12-17T05:25:40","slug":"dmvpn-with-bgp-ospf","status":"publish","type":"page","link":"https:\/\/technobabble.us.to\/?page_id=535","title":{"rendered":"DMVPN with BGP &#038; OSPF"},"content":{"rendered":"\n<p>While working on some older CCNP labs recently I needed to get rid of the frame relay that was used in the various labs since it&#8217;s no longer being used and is not supported in EVE-NG. I originally connected everything via a generic cloud and used ethernet interfaces since that is the only type Eve will support to the cloud. While this worked okay I did not like the direct connectivity I was seeing between the routers as it seemed like the DMVPN tunnel I was building was pointless. <\/p>\n\n\n\n<p>Then I decided to use EBGP as the Underlay for the DMVPN Overlay. I choose a very simple implementation where the hub and spokes all connect to the same &#8220;ISP&#8221;. This makes the scenario much easier since the ISP is just redistributing connected subnets. <\/p>\n\n\n\n<p>Now I&#8217;m using DMVPN in the place of Frame Relay for all of my labs and it&#8217;s working great. I had never worked with DMVPN before so this was a great lab. Originally it was just a simple OSPF lab that &#8220;morphed&#8221; into something far more interesting. I&#8217;ll post the configuration snippets below in case you are curious.     <\/p>\n\n\n\n<figure class=\"wp-block-gallery columns-1 is-cropped wp-block-gallery-1 is-layout-flex wp-block-gallery-is-layout-flex\"><ul class=\"blocks-gallery-grid\"><li class=\"blocks-gallery-item\"><figure><a href=\"https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM.png\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"695\" src=\"https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM-1024x695.png\" alt=\"\" data-id=\"434\" data-full-url=\"https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM.png\" data-link=\"https:\/\/technobabble.us.to\/2020\/02\/20\/dmvpn-with-bgp-ospf\/screen-shot-2020-02-20-at-6-17-54-pm\/\" class=\"wp-image-434\" srcset=\"https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM-1024x695.png 1024w, https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM-300x204.png 300w, https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM-768x521.png 768w, https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM-1536x1043.png 1536w, https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-6.17.54-PM-2048x1390.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure><\/li><\/ul><\/figure>\n\n\n\n<p><\/p>\n\n\n\n<p>ISP-SINGLE-REDISTRIBUTED  &#8211;&gt;  allowas-in (for multiple ISP&#8217;s)<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\nrouter bgp 1\n bgp log-neighbor-changes\n neighbor 11.11.11.1 remote-as 11\n neighbor 22.22.22.1 remote-as 22\n neighbor 44.44.44.1 remote-as 44\n network 11.11.11.0 mask 255.255.255.0\n network 22.22.22.0 mask 255.255.255.0\n network 44.44.44.0 mask 255.255.255.0\nend\n\nip route 11.11.11.0 255.255.255.0 Null0\nip route 22.22.22.0 255.255.255.0 Null0\nip route 44.44.44.0 255.255.255.0 Null0\n\ninterface Serial1\/0\n ip address 11.11.11.2 255.255.255.252\n serial restart-delay 0\n\ninterface Serial1\/2\n ip address 22.22.22.2 255.255.255.252\n serial restart-delay 0\n\ninterface Serial1\/3\n ip address 44.44.44.2 255.255.255.252\n serial restart-delay 0\nend\n\nBGP#sh ip bgp\n     Network          Next Hop            Metric LocPrf Weight Path\n *&gt;   11.11.11.0\/24    0.0.0.0                  0         32768 i\n *&gt;   22.22.22.0\/24    0.0.0.0                  0         32768 i\n *&gt;   44.44.44.0\/24    0.0.0.0                  0         32768 i\n<\/pre><\/div>\n\n\n<p>DMVPN-HUB<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ninterface Serial1\/0\n ip address 11.11.11.1 255.255.255.252\n serial restart-delay 0\n\nrouter bgp 11\n bgp log-neighbor-changes\n distribute-list 10 in\n network 11.11.11.0 mask 255.255.255.0\n neighbor 11.11.11.2 remote-as 1\nend\n\naccess-list 10 deny   11.11.11.0\naccess-list 10 permit any\n\nR1#sh ip bgp\n     Network          Next Hop            Metric LocPrf Weight Path\n *&gt;   22.22.22.0\/24    11.11.11.2               0             0 1 i\n *&gt;   44.44.44.0\/24    11.11.11.2               0             0 1 i\n\nHub#sh ip route bgp\nGateway of last resort is not set\n      22.0.0.0\/30 is subnetted, 1 subnets\nB        22.22.22.0 &#x5B;20\/0] via 11.11.11.2, 00:00:40\n      44.0.0.0\/30 is subnetted, 1 subnets\nB        44.44.44.0 &#x5B;20\/0] via 11.11.11.2, 00:00:40\n\ninterface Tunnel1\n ip address 10.1.110.1 255.255.255.0\n no ip redirects\n ip nhrp map multicast dynamic\n ip nhrp network-id 10\n ip ospf network point-to-multipoint\n ip ospf cost 64\n tunnel source 11.11.11.1\n tunnel mode gre multipoint\nend\n\nHUB#sh dmvpn | i 1\n        T1 - Route Installed, T2 - Nexthop-override\nInterface: Tunnel1, IPv4 NHRP Details \n     1 22.22.22.1           10.1.110.2    UP 01:02:32     D\n     1 44.44.44.1           10.1.110.4    UP 01:02:40     D\n\nrouter ospf 1\n router-id 10.1.1.1\n area 24 stub no-summary\n redistribute static subnets\n network 10.1.110.0 0.0.0.255 area 24\n network 10.1.116.0 0.0.0.255 area 0\n neighbor 10.1.110.2 cost 10\n\nHUB#sh ip ospf nei\nNeighbor ID     Pri   State           Dead Time   Address         Interface\n10.6.6.6          0   FULL\/  -        00:00:33    10.1.116.6      Serial1\/1\n10.4.4.4          0   FULL\/  -        00:01:56    10.1.110.4      Tunnel1\n10.2.2.2          0   FULL\/  -        00:01:36    10.1.110.2      Tunnel1\n<\/pre><\/div>\n\n\n<p>Spoke #1<\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ninterface Serial1\/2\n ip address 22.22.22.1 255.255.255.252\n serial restart-delay 0\nend\n\nrouter bgp 22\n bgp log-neighbor-changes\n distribute-list 10 in\n network 22.22.22.0 mask 255.255.255.0\n neighbor 22.22.22.2 remote-as 1\nend\n\naccess-list 10 deny   22.22.22.0\naccess-list 10 permit any\n\nR2#sh ip bgp\n     Network          Next Hop            Metric LocPrf Weight Path\n *&gt;   11.11.11.0\/24    22.22.22.2               0             0 1 i\n *&gt;   44.44.44.0\/24    22.22.22.2               0             0 1 i\n\nSpoke1#sh ip route bgp\nGateway of last resort is 10.1.110.1 to network 0.0.0.0\n      11.0.0.0\/30 is subnetted, 1 subnets\nB        11.11.11.0 &#x5B;20\/0] via 22.22.22.2, 00:00:40\n      44.0.0.0\/30 is subnetted, 1 subnets\nB        44.44.44.0 &#x5B;20\/0] via 22.22.22.2, 00:00:40\n\ninterface Tunnel1\n ip address 10.1.110.2 255.255.255.0\n no ip redirects\n ip nhrp map 10.1.110.1 11.11.11.1\n ip nhrp map multicast 11.11.11.1\n ip nhrp map 10.1.110.4 44.44.44.1\n ip nhrp map multicast 44.44.44.1\n ip nhrp network-id 10\n ip nhrp nhs 10.1.110.1\n ip nhrp nhs 10.1.110.4\n ip ospf network point-to-multipoint\n ip ospf cost 64\n tunnel source 22.22.22.1\n tunnel mode gre multipoint\nend\n\nSpoke1#sh dmvpn | i 1\n        T1 - Route Installed, T2 - Nexthop-override\nInterface: Tunnel1, IPv4 NHRP Details \n     1 11.11.11.1           10.1.110.1    UP 01:02:23     S\n     1 44.44.44.1           10.1.110.4    UP 00:16:21     S\n\nrouter ospf 1\n router-id 10.2.2.2\n area 24 stub\n network 10.1.110.0 0.0.0.255 area 24\n network 172.30.24.0 0.0.0.255 area 24\n distribute-list 10 in\nend\n\nSpoke1#sh ip ospf nei\n\nNeighbor ID     Pri   State           Dead Time   Address         Interface\n10.1.1.1          0   FULL\/  -        00:01:53    10.1.110.1      Tunnel1\n10.4.4.4          1   FULL\/DR         00:00:39    172.30.24.4     Ethernet0\/0\n<\/pre><\/div>\n\n\n<p>Spoke #2 <\/p>\n\n\n<div class=\"wp-block-syntaxhighlighter-code \"><pre class=\"brush: plain; title: ; notranslate\" title=\"\">\ninterface Serial1\/3\n ip address 44.44.44.1 255.255.255.252\n serial restart-delay 0\nend\n\nrouter bgp 44\n bgp log-neighbor-changes\n distribute-list 10 in\n network 44.44.44.0 mask 255.255.255.0\n neighbor 44.44.44.2 remote-as 1\nend\n\naccess-list 10 deny   44.44.44.0\naccess-list 10 permit any\n\nR4#sh ip bgp\n     Network          Next Hop            Metric LocPrf Weight Path\n *&gt;   11.11.11.0\/24    44.44.44.2               0             0 1 i\n *&gt;   22.22.22.0\/24    44.44.44.2               0             0 1 i\n\nSpoke2#sh ip route bgp\nGateway of last resort is 10.1.110.1 to network 0.0.0.0\n      11.0.0.0\/30 is subnetted, 1 subnets\nB        11.11.11.0 &#x5B;20\/0] via 44.44.44.2, 00:00:40\n      22.0.0.0\/30 is subnetted, 1 subnets\nB        22.22.22.0 &#x5B;20\/0] via 44.44.44.2, 00:00:40\n\ninterface Tunnel1\n ip address 10.1.110.4 255.255.255.0\n no ip redirects\n ip nhrp map 10.1.110.1 11.11.11.1\n ip nhrp map multicast 11.11.11.1\n ip nhrp map 10.1.110.2 22.22.22.1\n ip nhrp map multicast 22.22.22.1\n ip nhrp network-id 10\n ip nhrp nhs 10.1.110.1\n ip nhrp nhs 10.1.110.2\n ip ospf network point-to-multipoint\n ip ospf cost 64\n tunnel source 44.44.44.1\n tunnel mode gre multipoint\nend\n\nSpoke2#sh dmvpn | i 1\n        T1 - Route Installed, T2 - Nexthop-override\nInterface: Tunnel1, IPv4 NHRP Details \n     1 11.11.11.1           10.1.110.1    UP 00:12:38     S\n     1 22.22.22.1           10.1.110.2    UP 00:12:38     S\n\nrouter ospf 1\n router-id 10.4.4.4\n area 24 stub\n network 10.1.110.0 0.0.0.255 area 24\n network 172.30.24.0 0.0.0.255 area 24\nend\n\nSpoke2#sh ip ospf nei\nNeighbor ID     Pri   State           Dead Time   Address         Interface\n10.1.1.1          0   FULL\/  -        00:01:53    10.1.110.1      Tunnel1\n10.2.2.2          1   FULL\/BDR        00:00:36    172.30.24.2     Ethernet0\/0\n<\/pre><\/div>\n\n\n<p>When I get some extra time I&#8217;ll add 2 more ISP routers so that each site it connecting to a different instance of AS1. Then I&#8217;ll use iBGP within AS1 to forward the routes accordingly and verify that the tunnel can still be built through various hops as opposed to all meeting on the same AS1 router. This method is a better approximation of a real world scenario. <\/p>\n\n\n\n<p>Another option would be to use EBGP and have each site use a different ISP. Then make the different Autonomous Systems talk to each other to form the tunnel, another very likely real world scenario and one of the whole reasons for using DMVPN.<\/p>\n\n\n\n<figure class=\"wp-block-gallery columns-1 is-cropped wp-block-gallery-2 is-layout-flex wp-block-gallery-is-layout-flex\"><ul class=\"blocks-gallery-grid\"><li class=\"blocks-gallery-item\"><figure><img decoding=\"async\" src=\"https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-11.05.54-AM-1024x689.png\" alt=\"\" data-id=\"416\" data-full-url=\"https:\/\/technobabble.us.to\/wp-content\/uploads\/2020\/02\/Screen-Shot-2020-02-20-at-11.05.54-AM.png\" data-link=\"https:\/\/technobabble.us.to\/2020\/02\/20\/dmvpn-with-bgp-ospf\/screen-shot-2020-02-20-at-11-05-54-am\/\" class=\"wp-image-416\"\/><\/figure><\/li><\/ul><figcaption class=\"blocks-gallery-caption\"> <\/figcaption><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>While working on some older CCNP labs recently I needed to get rid of the frame relay that was used in the various labs since it&#8217;s no longer being used and is not supported in EVE-NG. I originally connected everything &hellip; <a href=\"https:\/\/technobabble.us.to\/?page_id=535\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":329,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-535","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/pages\/535","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/technobabble.us.to\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=535"}],"version-history":[{"count":1,"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/pages\/535\/revisions"}],"predecessor-version":[{"id":536,"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/pages\/535\/revisions\/536"}],"up":[{"embeddable":true,"href":"https:\/\/technobabble.us.to\/index.php?rest_route=\/wp\/v2\/pages\/329"}],"wp:attachment":[{"href":"https:\/\/technobabble.us.to\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=535"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}