BGP: Difference between revisions
→Community
Line 222:
*Configuration
;R1 Config:
ip bgp-community new-format
route-map SETCOM
set community 1:10
router bgp 12
neighbor 192.168.12.2 remote-as 12
neighbor 192.168.12.2 send-community
'''network 150.1.1.0 mask 255.255.255.0 route-map SETCOM'''▼
▲ network 150.1.1.0 mask 255.255.255.0 route-map SETCOM
▲;R2 Config(Before applying any policies):
▲ R2# sh ip bgp 150.1.1.0
Flag: 0x820
▲ BGP routing table entry for 150.1.1.0/24, version 2
▲ Paths: (1 available, best #1, table Default-IP-Routing-Table)
▲ Not advertised to any peer
▲ 192.168.12.1 from 192.168.12.1 (192.168.127.1)
▲ Origin IGP, '''metric 0''', localpref 100, valid, internal, best
▲ '''Community: 1:10'''
;R2 Config: Match the community using a standard community-list▼
▲;Match the community using a standard community-list
ip community-list 1 permit 1:10
route-map COM
router bgp 12
;R2 Config: After applying the policy:
R2 #sh ip bgp 150.1.1.0/24
= Route Aggregation =
|