bgp--选路
1、配ip
2、底层用rip和ospf
3、起bgp

bgp--选路
4、选路
1)AS1去AS2走R1-R3,可以用Local_pref,即在R1上抓取AS2的流量,增大Local值,在R3的入向调用
[r1]ip ip-prefix 2 permit 100.2.3.3 32
[r1]ip ip-prefix 2 permit 100.2.4.4 32
[r1]route-policy b permit node 10
[r1-route-policy]if-match ip-prefix 2
[r1-route-policy]apply local-preference 120
[r1]route-policy b permit node 20
[r1-bgp]peer 10.1.13.2 route-policy b import

bgp--选路
bgp--选路
2)AS2去AS1走R4-R2,可以使用Med,在R3上抓取AS1的流量,增大MED值,
[r3]ip ip-prefix 1 permit 100.1.1.1 32
[r3]ip ip-prefix 1 permit 100.1.2.2 32
[r3]route-policy a permit node 10
[r3-route-policy]if-match ip-prefix 1
[r3-route-policy]apply cost 100
[r3]route-policy a permit node 20
[r3-bgp]peer 10.1.13.1 route-policy a import
bgp--选路
bgp--选路
3) AS1去AS3走R2-R6,使用as-path,在R2上,抓取AS3的流量,增加AS-path,
ip ip-prefix 3 index 10 permit 100.3.0.0 16 greater-equal 17 less-equal 32
route-policy c permit node 10
if-match ip-prefix 3
apply as-path 5 additive

[r2]route-policy c permit node 20
peer 10.1.25.2 route-policy c import
bgp--选路
4)AS2去AS3走R4-R6,使用prefval,在R4上,抓取AS3的流量,增加PrefVal
[r4]ip ip-prefix 4 permit 100.3.0.0 16 greater-equal 17
[r4]route-policy d permit node 10
[r4-route-policy]if-match ip-prefix 4
[r4-route-policy]apply preferred-value 130
[r4-bgp]peer 10.2.46.2 route-policy d import
[r4]route-policy d permit node 20

bgp--选路

相关文章:

  • 2021-05-26
  • 2021-06-25
  • 2021-09-17
  • 2021-11-04
  • 2022-01-06
  • 2021-11-24
猜你喜欢
  • 2021-05-17
  • 2022-01-14
  • 2021-07-08
  • 2021-12-01
  • 2021-08-24
相关资源
相似解决方案