BGP COST Extended Community Attribute

Hi @Network_Eric

i can`t understand what is the bgp cost extended community attribute used for

please everyone just foucs with 2.2.2.2/32 on R2 . i`m gonig to explain my question on steps to be easier.

step-1 > R2 advertise 2/32 to R4 PE-3 as eigrp update and R3 redistribute it into bgp as VPNv4 NLRI and send it to R3 as an iBGP update

step-2>R2 advertise 2/32 to R3 as an eigrp update and R3 redistribute it into bgp as an VPNv4 NLRI.

R3#show ip bgp vpnv4 all

  • i 2.2.2.2/32 4.4.4.4 156160 100 0 ?
    *> 10.1.13.1 158720 32768 ?
    so far so good. R3 has expected 2/32 TWO times as i expect to see.

step-3> i`m going to configured bgp cost extended commnuity attribute on R4 and i want to see what will happened

R4(config)#ip prefix-list test permit 2.2.2.2/32
R4(config)#route-map ine permit 10
R4(config-route-map)#match ip address prefix-list test
R4(config-route-map)#set extcommunity cost pre-bestpath 128 200
!
128 means here the route is internal eigrp route
200 means this route has eigrp metric value=200
!
R4(config)#router bgp 100
R4(config-router)#address-family vpnv4 unicast
R4(config-router-af)#neighbor 3.3.3.3 route-map ine out
R4(config-router-af)#do clear bgp *
R3#show ip bgp vpnv4 all
*>i 2.2.2.2/32 4.4.4.4 156160 100 0 ?
the question now is, why R3 has only one route 2/32? where is the other route from R1 ? what happened here?

thanks