BGP MED Configuration [Gns3 Lab]

Learner 0

Lets configure BGP and change the MED for each destination:

* R2 configuration:

We will prefer the 4.4.4.2 to pass through R2 by giving it a lower metric (100) and 4.4.4.3 a higher metric (200).

router bgp 277
no synchronization
bgp log-neighbor-changes
neighbor 10.0.0.1 remote-as 266
neighbor 10.0.0.1 route-map MEDI out
neighbor 10.0.0.10 remote-as 277
no auto-summary

access-list 1 permit 4.4.4.2
access-list 2 permit 4.4.4.3
!
route-map MEDI permit 10
match ip address 1
set metric 100
!
route-map MEDI permit 20
match ip address 2
set metric 200

* R3 configuration:

router bgp 277
 no synchronization
 bgp log-neighbor-changes
 neighbor 10.0.0.5 remote-as 266
 neighbor 10.0.0.5 route-map MEDI out
 neighbor 10.0.0.14 remote-as 277
 no auto-summary
!

access-list 1 permit 4.4.4.2
access-list 2 permit 4.4.4.3

route-map MEDI permit 10
 match ip address 1
 set metric 200
!
route-map MEDI permit 20
 match ip address 2
 set metric 100
!