Cisco Labs – Redundant and Resilient networks (1) – BGP confederations


Introduction

During my university studies I was doing a diploma thesis in field of Redundant and reliable networking. The purpose of itwas to create LAB examples for students, so they can test First Hop Redundancy Protocols (FHRP) , Any Transport over MPLS (AToM) and Border Gateway Protocol (BGP) on Cisco platform. These tasks are created to Virtlab (Virtual lab with physical Cisco routers) however configuration is valid and tested on physical Cisco routers as well.

Each task in the series will have its separate post with brief description of the task and schema. Complete task can be downloaded on My Skydrive

ZIP file contains:

  • *.HTML file – complete step by step guide how to perform the task
  • *.PNG – pictures with topology and others
  • *_preconf.txt – file with basic configuration of topology to be able to focus on task goal (IP addresses, interfaces and so on)
  • *_end.txt – file with complete configuration. Once put to the routers, you will get working task
  • *.dia – Topology in free DIA editor
  • *.XML – topology in XML format

To complete the task:

  • Connect your environment accorrding the topology
  • open the file *_preconf.txt from ZIP file with complete task and configure your environment with basic settings so you can start with the task.

BGP – confederations 

Title: BGP – confederations

Goal:

  • Configure BGP confederations on topology with preconfigured OSPF,RIP routing inside sub-ASes of the confederation AS.

Required time: 120 minutes

Theoretical background:

Theoretical introduction into BGP:

Configuration and command reference for BGP,OSPF and EIGRP:

Topology:

BGP-Confederations

Configuration:

1) Check pre-configured settings

Before starting the configuration of BGP, make sure that routers configuration and network operation are correct. Topology is pre-configured so that every sub-AS has its own interior routing protocol configured
(OSPF, RIP) with passive interface between sub-ASes to prevent IGP connection. Use pingcommand to test connectivity. You should be able to ping all networks inside particular BGP sub-AS.

2) Perform step 1 of function test

3) Configure BGP

Router RA:

Pay attention! BGP sessions must be full-meshed inside sub-AS, as shown in sub-AS 65101 configuration.

      RA(config)#router bgp 65101; set confederation sub-AS number and start BGP process
      RA(config-router)#no synchronization ; disable synchronization between BGP and IGP
      RA(config-router)#bgp router-id 2.0.0.3; set unique BGP router ID
      RA(config-router)#bgp log-neighbor-changes; log neighbor changes
      RA(config-router)#redistribute connected; redistribute interior networks via BGP to other ASes
      RA(config-router)#bgp confederation identifier 100; set sub-AS 65101 as part of confederation 100
      RA(config-router)#bgp confederation peers 65102; set another sub AS 65102 to be a peer in confederation 100
      RA(config-router)#neighbor 10.1.0.2 remote-as 65101; set BGP neighbor to be part of the same sub AS to fulfill full mesh requirement
      RA(config-router)#neighbor 10.2.0.1 remote-as 65101; set BGP neighbor to be part of the same sub AS to fulfill full mesh requirement
      RA(config-router)#no auto-summary; do not summarize networks

Router RB:

      RB(config)#router bgp 65101
      RB(config-router)#no synchronization
      RB(config-router)#bgp router-id 2.0.0.1
      RB(config-router)#bgp log-neighbor-changes
      RB(config-router)#redistribute connected
      RB(config-router)#bgp confederation identifier 100
      RB(config-router)#bgp confederation peers 65102
      RB(config-router)#neighbor 11.0.0.2 remote-as 200; set BGP neighbor in external AS 200
      RB(config-router)#neighbor 10.1.0.1 remote-as 65101; set BGP neighbor to be part of the same sub AS to fulfill full mesh requirement
      RB(config-router)#neighbor 10.2.0.1 remote-as 65101; set BGP neighbor to be part of the same sub AS to fulfill full mesh requirement
      RB(config-router)#no auto-summary

Similarly RC:

      RC(config)#router bgp 65101
      RC(config-router)#no synchronization
      RC(config-router)#bgp router-id 2.0.0.2
      RC(config-router)#bgp log-neighbor-changes
      RC(config-router)#redistribute connected
      RC(config-router)#bgp confederation identifier 100
      RC(config-router)#bgp confederation peers 65102
      RC(config-router)#neighbor 10.3.0.1 remote-as 65102
      RC(config-router)#neighbor 10.1.0.2 remote-as 65101
      RC(config-router)#neighbor 10.2.0.2 remote-as 65101
      RC(config-router)#no auto-summary

Similarly for AS65201

Router RD:

      RD(config)#router bgp 65201
      RD(config-router)#no synchronization 
      RD(config-router)#bgp router-id 5.0.0.2
      RD(config-router)#bgp log-neighbor-changes
      RD(config-router)#redistribute connected
      RD(config-router)#bgp confederation identifier 200
      RD(config-router)#bgp confederation peers 65202
      RD(config-router)#neighbor 11.0.0.1 remote-as 100
      RD(config-router)#neighbor 100.23.0.2 remote-as 65202
      RD(config-router)#no auto-summary

Similarly for AS65202

Router RE:

      RE(config)#router bgp 65202
      RE(config-router)#no synchronization
      RE(config-router)#bgp router-id 6.0.0.2
      RE(config-router)#bgp log-neighbor-changes
      RE(config-router)#redistribute connected
      RE(config-router)#bgp confederation identifier 200
      RE(config-router)#bgp confederation peers 65201
      RE(config-router)#neighbor 12.0.0.2 remote-as 100
      RE(config-router)#neighbor 100.23.0.1 remote-as 65201
      RE(config-router)#no auto-summary

Similarly for AS65102

Router RF:

      RF(config)#router bgp 65102
      RF(config-router)#no synchronization
      RF(config-router)#bgp router-id 4.0.0.1
      RF(config-router)#bgp log-neighbor-changes
      RF(config-router)#redistribute connected
      RF(config-router)#bgp confederation identifier 100
      RF(config-router)#bgp confederation peers 65101
      RF(config-router)#neighbor 12.0.0.1 remote-as 200
      RF(config-router)#neighbor 10.4.0.2 remote-as 65102
      RF(config-router)#no auto-summary

Router RG:

      RG(config)#router bgp 65102
      RG(config-router)#no synchronization
      RG(config-router)#bgp router-id 4.0.0.2
      RG(config-router)#bgp log-neighbor-changes
      RG(config-router)#bgp confederation identifier 100
      RG(config-router)#bgp confederation peers 65101
      RG(config-router)#redistribute connected
      RG(config-router)#neighbor 10.3.0.2 remote-as 65101
      RG(config-router)#neighbor 10.4.0.1 remote-as 65102
      RG(config-router)# auto-summary

Function test:

1) Display routing information before you configure BGP

Verify routing tables on all routers of the network using sh ip route command.
Verify BGP using sh ip bgp neighbor and sh ip bgp on RA and RD.

      Rx# sh ip route

2) Display routing information with BGP configured

Verify routing tables on all routers of the network using sh ip route command.
Verify BGP using sh ip bgp neighbor and sh ip bgp on RA and RD.

      Rx# sh ip route; x represents every router in topology
      Rx# sh ip bgp summary
      Rx# sh ip bgp neighbor
      Rx# sh ip bgp
      Rx# sh ip ospf neighbors

3) Test connectivity

Test connectivity between AS100 and AS200. For example use ping command from RA to one of the interfaces on router RG. Also test connectivity to other routers.

      RA# ping 100.23.0.2
      RA# traceroute 100.23.0.2

4) Compare routing tables in AS100 and AS200

BGP path in routing table will show confederation AS number instead of sub-AS numbers.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s