Saturday, November 24, 2018

Sanity Check - BGP Multihoming with 2 ISPs and 2 Routers

I'm going to be turning up a secondary ISP connection in one of my data centers. I have little real-world experience with BGP, so I wanted to double check that nothing I was planning on doing is egregiously wrong.

Requirements

  • All inbound and outbound traffic routes through ISP-A by default
  • ISP B is only used in the event of a failure on Router 1, or if I lose routes from ISP-A
  • In the event that I do lose routes from ISP-A, I don't particularly mind if outbound traffic has an extra hop through Router 1 to reach Router 2 and ISP-B, so I'm not planning on tracking HSRP at all

Topology

https://imgur.com/a/RFsBu1l

BGP Configs

Router 1:

ip route 3.3.3.0 255.255.254.0 Null0 name BGP_SEED_ROUTE ip prefix-list TO_ISP seq 10 permit 3.3.3.0/23 route-map SET_LOCALPREF permit 10 set local-preference 150 route-map TO_ISP permit 10 match ip address prefix-list TO_ISP router bgp 3333 network 3.3.3.0 mask 255.255.254.0 neighbor 172.32.1.2 remote-as 3333 neighbor 172.32.1.2 description iBGP Connection to Router 2 neighbor 172.32.1.2 update-source Loopback0 neighbor 172.32.1.2 soft-reconfiguration inbound neighbor 172.32.1.2 next-hop-self neighbor 1.1.1.1 remote-as 1111 neighbor 1.1.1.1 description Connection to ISP A neighbor 1.1.1.1 soft-reconfiguration inbound neighbor 1.1.1.1 route-map SET_LOCALPREF in neighbor 1.1.1.1 route-map TO_ISP out 

Router 2:

ip route 3.3.3.0 255.255.254.0 Null0 name BGP_SEED_ROUTE ip prefix-list TO_ISP seq 10 permit 3.3.3.0/23 route-map TO_ISP permit 10 match ip address prefix-list TO_ISP set as-path prepend 3333 3333 3333 router bgp 3333 network 3.3.3.0 mask 255.255.254.0 neighbor 172.32.1.1 remote-as 3333 neighbor 172.32.1.1 description iBGP Connection to Router 1 neighbor 172.32.1.1 update-source Loopback0 neighbor 172.32.1.1 soft-reconfiguration inbound neighbor 172.32.1.1 next-hop-self neighbor 2.2.2.1 remote-as 2222 neighbor 2.2.2.1 description Connection to ISP B neighbor 2.2.2.1 soft-reconfiguration inbound neighbor 2.2.2.1 route-map TO_ISP out 


No comments:

Post a Comment