BGP Weight 이론 및 실습
Cisco 전용으로 BGP 경로 설정에 있어 가장 최우시 되는 속성으로 동일 라우터 내에서 경로가 2개 이상 있을 경우에 Weight 값으로 Best 경로를 선출한다.
Topology
Command ( 기본 설정 제외 )
Router(config-router)#neighbor ip-address weight value // 모든 네트워크 정보에 weight 부여
// 특정 네트워크에 route-map 이용하여 weight 부여
Router(config)#route-map map-name permit seq
Router(config-route-map)#match ip address access-list-number
Router(config-route-map)#set weight value
Router(config-route)#neighbor ip-address route-map map-name in
=> R8의 네이버인 7.7.7.7에서 3.3.3.3에서 오는 ip의 Weight을 200으로 설정
- route-map 이용하여 특정경로 설정 -
R8(config)#access-list 10 permit 3.3.3.0 0.0.0.255
R8(config)#route-map WT permit 10
R8(config-route-map)#match ip address 10
R8(config-route-map)#set weight 200
R8(config)#route-map wt permit 20 // 모두 허용
R8(config-route-map)#router bgp 400
R8(config-router)#neighbor 7.7.7.7 route-map WT in
Check
Command ( 기본 설정 제외 )
=>R7에서 네이버인 8.8.8.8에서 오는 ip의 Weight을 400으로 설정
- neighbor 이용하여 모든경로 설정 -
R7(config)#router bgp 400
R7(config-router)#neighbor 8.8.8.8 weight 40
Check