iBGP Introduction

February 5, 2025 - Reading time: 3 minutes

BGP (Border Gateway Protocol) is the backbone of the internet, enabling networks to communicate and exchange routing information. It allows routers to determine the best path for forwarding data between different networks, known as Autonomous Systems (ASes).

There are two types of BGP:

  • eBGP (External BGP) – Used between different networks, like between two Internet providers or a company and its internet provider.
  • iBGP (Internal BGP) – Used within the same network to keep routing consistent.

In this lesson, we’ll configure iBGP between two routers in the same Autonomous System (AS). Using AS 2350, Router0 will advertise the networks 50.50.50.0/24 and 70.70.0.0/16, and Router1 will receive these routes through the iBGP session and install them into its routing table.


iBGP peering and network advertising

Device Setup Router0

  1. Assign IP addresses to interfaces:

    Router0# configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router0(config)# interface fastethernet 0/0
    Router0(config-if)# ip address 192.168.86.45 255.255.255.0
    Router0(config-if)# no shutdown
    Router0(config-if)# exit
    
    Router0(config)# interface loopback 0
    Router0(config-if)# ip address 1.1.1.1 255.255.255.255
    Router0(config-if)# exit

    Router0(config)# interface loopback 50 Router0(config-if)# ip address 50.50.50.1 255.255.255.0 Router0(config-if)# exit

    Router0(config)# interface loopback 70 Router0(config-if)# ip address 70.70.70.1 255.255.0.0 Router0(config-if)# exit

    Router0(config)# end
    Router0#
  2. Configure iBGP:

    Router0# configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router0(config)# router bgp 2350
    Router0(config-router)# neighbor 192.168.86.40 remote-as 2350
    Router0(config-router)# network 50.50.50.0 255.255.255.0
    Router0(config-router)# network 70.70.70.0 255.255.0.0
    Router0(config-router)# exit
    Router0(config)# end
    Router0#

    Router0 is running BGP in AS 2350. It establishes an iBGP peering with the neighbor at 192.168.86.40 and advertises two networks—50.50.50.0/24 and 70.70.0.0/16—into the BGP domain.

Device Setup Router1

  1. Assign IP addresses to interfaces:

    Router1# configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router1(config)# interface gigabitEthernet0/0
    Router1(config-if)# ip address 192.168.86.40 255.255.255.0
    Router1(config-if)# no shutdown
    Router1(config-if)# exit
    Router1(config)# end
    Router1#
    
  2. Configure iBGP:

    Router1# configure terminal
    Enter configuration commands, one per line.  End with CNTL/Z.
    Router1(config)# router bgp 2350
    Router1(config-router)# neighbor 192.168.86.45 remote-as 2350
    Router1(config-router)# exit
    Router1(config)# end
    Router1#

    Router1 is running BGP in AS 2350 and is set up to form an iBGP peering with the router at 192.168.86.45. Unlike Router0, it does not advertise any networks into BGP here—its only role is to establish the iBGP session.


Assumptions & Troubleshooting

📝 Note:
This configuration assumes that synchronization and auto-summary are disabled.
If the BGP session is established but routes are not behaving as expected, add the following commands under the BGP configuration on both routers:

Router(config-router)# no synchronization
Router(config-router)# no auto-summary
  • no synchronization: Ensures BGP can advertise routes without requiring them to be present in the IGP.
  • no auto-summary: Prevents automatic summarization of classful networks, ensuring that subnet-specific advertisements are not lost.

Recap

  • iBGP is used for routing within the same AS.
  • Each router must use the same AS number in the router bgp <AS> command.
  • Neighbors must be IP reachable (often directly connected or via an IGP) for BGP to establish a session.
  • You must advertise networks with the network statement so that they appear in your BGP updates.
  • If routes are missing, verify synchronization and auto-summary settings.

Challenge

See if you can advertise Loopback1 from both devices.

Verify your configuration using the following commands:

show ip bgp summary
show ip bgp
show ip route

We will dig deeper into BGP verification in the next lesson.


Lab Download

The lab is available for download from this link. (minimum requirement: version 2.5)

iBGP Introduction | PocketCLI

Download


>