Thursday, September 15, 2016

Cisco 3750-X: BGP Configuration

When I was leaving the VAR I was working at a few months ago, one of the last things I did was to configure BGP on a Cisco switch for dual ISP connections.  If I recall, this was a 3750-X.  Below is the config, along with a show command to verify BGP routes.

BGP CONFIG:
int  Vlan1
 description ** 100Meg Circuit 1 **
 ip address 4.4.4.38 255.255.255.252
!
interface Vlan2
 description ** 100Meg Circuit: 2 **
 ip address 12.12.12.210 255.255.255.252
!
interface Vlan3
 description *** Company Side IP ***
 ip address 7.7.7.129 255.255.255.192
!
router bgp 65010
 bgp log-neighbor-changes
 network 7.7.7.128 mask 255.255.255.192
 neighbor 4.4.4.37 remote-as 4323
 neighbor 4.4.4.37 prefix-list Companyroute out
 neighbor 12.12.12.209 remote-as 4323
 neighbor 12.12.12.209 prefix-list Companyroute out
 maximum-paths 2
 maximum-paths ibgp 2
!
ip prefix-list Companyroute seq 5 permit 7.7.7.128/26

SHOW THE ROUTES:
Switch#sh ip bgp neighbor 12.12.12.209 adv
BGP table version is 14, local router ID is 12.12.12.210
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
              r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter,
              x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

     Network          Next Hop            Metric LocPrf Weight Path
 *>  7.7.7.128/26
                       0.0.0.0                  0         32768 i

Total number of prefixes 1
Switch#sh ip bgp nei 4.4.4.37 advertised-routes
BGP table version is 14, local router ID is 12.12.12.210
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
              r RIB-failure, S Stale, m multipath, b backup-path, f RT-Filter,
              x best-external, a additional-path, c RIB-compressed,
Origin codes: i - IGP, e - EGP, ? - incomplete
RPKI validation codes: V valid, I invalid, N Not found

     Network          Next Hop            Metric LocPrf Weight Path
 *>  7.7.7.128/26
                       0.0.0.0                  0         32768 i

Total number of prefixes 1
Switch#sh ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       E1 - OSPF external type 1, E2 - OSPF external type 2
       i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
       ia - IS-IS inter area, * - candidate default, U - per-user static route
       o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is 12.12.12.209 to network 0.0.0.0

B*    0.0.0.0/0 [20/0] via 12.12.12.209, 00:13:44
                [20/0] via 4.4.4.37, 00:13:44
      66.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        4.4.4.36/30 is directly connected, Vlan1
L        4.4.4.38/32 is directly connected, Vlan1
      173.227.0.0/16 is variably subnetted, 2 subnets, 2 masks
C        7.7.7.128/26 is directly connected, Vlan3
L        7.7.7.129/32 is directly connected, Vlan3
      12.12.12.0/24 is variably subnetted, 2 subnets, 2 masks
C        12.12.12.208/30 is directly connected, Vlan2
L        12.12.12.210/32 is directly connected, Vlan2
Switch#

No comments:

Post a Comment

Your comment will be reviewed for approval. Thank you for submitting your comments.