BGP with Attributes | Cisco router | AI Study

 Here is an example of a more advanced BGP configuration for a Cisco router that is connected to a point-to-point (p2p) VLAN and other networks, including the use of path prepend and the multi-exit discriminator (MED) weight attribute:

router bgp 100 bgp log-neighbor-changes no synchronization network 10.0.0.0 mask 255.0.0.0 network 10.1.1.0 mask 255.255.255.0 neighbor 10.1.1.2 remote-as 200 neighbor 10.1.1.2 update-source Vlan1 neighbor 10.1.1.2 next-hop-self neighbor 10.1.1.2 soft-reconfiguration inbound neighbor 10.1.1.2 route-map bgp-in in neighbor 10.1.1.2 route-map bgp-out out neighbor 10.1.1.2 weight 100 neighbor 10.1.1.2 prefix-list p2p-filter in route-map bgp-out permit 10 match ip address prefix-list p2p-filter set as-path prepend 100 100 set med 100 prefix-list p2p-filter seq 5 permit 10.1.1.0/24

This configuration sets up a BGP router with an autonomous system number of 100. The "bgp log-neighbor-changes" command is used to log BGP neighbor changes. The "no synchronization" command disables the requirement for BGP routers to have the same routing information before forming a neighbor relationship.

The "network" command is used to advertise the 10.0.0.0/8 and 10.1.1.0/24 networks to BGP neighbors. The "neighbor" command is used to configure a BGP neighbor with IP address 10.1.1.2 and autonomous system number 200. The "update-source" command is used to specify the source IP address for BGP updates, in this case, the Vlan1 interface. The "next-hop-self" command is used to make the next hop for the routes learned from this neighbor be the IP address of the local router.

The "soft-reconfiguration inbound" command allows the router to save the routing information from BGP neighbors in memory, so that it can be used for fast inbound soft reconfiguration. The "route-map" command is used to apply a route map to inbound and outbound BGP updates. The "weight" command is used to assign a weight value to the BGP routes learned from this neighbor.

The "prefix-list" command is used to filter the routes that will be sent to the neighbor, in this case, only the 10.1.1.0/24 network is allowed.

The "route-map" command is used to apply a route map to outbound BGP updates. The "match ip address prefix-list" command is used to match the prefix-list that was defined earlier. The "set as-path prepend" command is used to prepend the local AS number twice to the AS_PATH, in this case, 100 100. The "set med" command is used to set the multi-exit discriminator value to 100.

Please note that this is a more advanced configuration, and there are many more options and parameters that can be configured depending on the specific requirements of the network

Comments

Popular posts from this blog

Advance BGP Configure | Cisco Router | AI Study

Arista Switch Configure |VLANs, LACP, management IP, trunk port, and RSTP| AI Study

AI tips and tricks for a support engineer