Single BGP Session - Multi Address Families


In this article, I want to show you how we can use one BGP session to carry both ipv4 and ipv6!

BGP

As you can see in our topology, we have two routers. They connected with one link. We have here two IPs. One IPV4, one IPV6.

Here I show you configuration under interface gig0/1 on both routers:

BGP

BGP

Now we are going to create BGP (eBGP) between R1 and R2

First command that we have to issue is:

# no bgp default ipv4-unicast

With this command, BGP is getting ready for multiprotocol function.

BGP, by default, is using ipv4 unicast peering session establishment.

But we have also ipv6 in our demo.

After this command, we have to add every defined neighbor to each intended address family using activate command.

BGP

To continue, we define neighbor and remote-as.

Next, we create two address-family, one for ipv4 and one for ipv6, and finally, with neighbor activate command we assign neighbor to related AF(address-family)

Check the configuration:

BGP

Now BGP session is established (two individual sessions).

Let's see the verification:

BGP

BGP

Based on verification, we have two BGP session between R1 and R2

Single BGP Session for both IPv4 and IPv6

Now to reduce overhead and make it more convenient we want to merge two BGP sessions between R1 and R2 into only one session!

Solution - configuration

Step 1- we have to create a route-map

In this route-map, we set the next-hop to our self ipv6 address.

So please pay attention. Our ipv6 address (int g0/1)!

BGP

Step 2- in address-family ipv6

Change the neighbor ipv6 into neighbor ipv4 address and bind the route-map to it.

See the configuration:

BGP

Last step is verification:

BGP

BGP

So now we have only one BGP session for both ipv4 and ipv6.

Video of this article

Thank you very much and waiting for your feedback!

534
0
0
Leave your comment