bgp联盟

配置ip地址和换回口地址

1.在R1与R6上另外各加2个环回口

R1:

interface LoopBack1
  ip address 192.168.200.1 255.255.255.255

R6:

interface LoopBack1
  ip address 192.168.100.1 255.255.255.255

2.R2/R3/R4/R5/R6做ospf

以R2为例:

ospf 1 
area 0.0.0.0 
network 10.2.11.1 0.0.0.0 
network 10.2.23.2 0.0.0.0

3.需要R1与R2建立ebgp邻居(用直连口建立)

R1:

bgp 100
  router-id 10.2.11.1
  peer 10.2.12.2 as-number 200

  network 10.2.11.1 255.255.255.255 (宣告自己的loop back接口)

  network 192.168.200.1 255.255.255.255(宣告自己的loop back接口)

R2:

bgp 65001
  router-id 10.2.22.2
  confederation id 200(配置联盟)
  confederation peer-as 65002
  peer 10.2.12.1 as-number 100
  network 10.2.22.2 255.255.255.255 

  import-route ospf 

4.R2<=>R3建立EBPGP邻居

R2:

bgp 65001

  peer 10.2.23.3 as-number 65002

R3:

bgp 65002
  router-id 10.2.33.3
  confederation id 200
  confederation peer-as 65001 65003
  peer 10.2.23.2 as-number 65001
  peer 10.2.35.5 as-number 65003

  network 10.2.33.3 255.255.255.255

 R3<=>R4建立Ibgp邻居

R3:

bgp 65002

  peer 10.2.34.4 as-number 65002 

R4:

bgp 65002

  router-id 10.2.44.4

  confederation id 200

  peer 10.2.34.3 as-number 65002

R3<=>R5建立EBPGP邻居

R5:

bgp 65003
  router-id 10.2.55.5
  confederation id 200
  confederation peer-as 65002
  peer 10.2.35.3 as-number 65002
  peer 10.2.56.6 as-number 65003

  network 10.2.55.5 255.255.255.255

R5<=>R6建立Ibgp邻居

R6:

bgp 65003
  router-id 10.2.66.6
  confederation id 200
  peer 10.2.56.5 as-number 65003

5.修改吓一跳

R2/R3/R5上都需要修改

R2:

bgp 65001

  peer 10.2.12.1 next-hop-local
  peer 10.2.23.3 next-hop-local

R3为例: 

bgp 65002

  peer 10.2.34.4 next-hop-local

  peer 10.2.35.5 next-hop-local

R5:

bgp 65003

  peer 10.2.56.6 next-hop-local

6.全网通

  

 

posted on 2019-08-18 17:16  _Adolescent*  阅读(303)  评论(0编辑  收藏  举报