BGP 路由反射器

网络工程 路由 BGP
2022-03-03 11:02:37

在以下配置中,INTERNAL1 和 INTERNAL4 是 RR,而 INTERNAL2 和 INTERNAL3 是客户端。我在 INTERNAL3 上看不到路线 20.1.1.0 和 10.1.1.0,在 INTERNAL2 上看不到 30.1.1.0 和 40.1.1.0。10.1.1.0连接到ISP1的fa0/0,20.1.1.0连接到ISP2的fa0/0,30.1.1.0连接到ISP3的fa0/0,40.1.1.0连接到ISP4的fa0/0。我无法理解为什么 RR 不将路由进一步从 INTERNAL2 到 INTERNAL3 广告到另一侧,反之亦然?拓扑

INTERNAL2(config)#do sh ip route
Gateway of last resort is not set

     20.0.0.0/24 is subnetted, 1 subnets
B       20.1.1.0 [20/0] via 112.1.1.2, 00:06:58
     112.0.0.0/24 is subnetted, 1 subnets
C       112.1.1.0 is directly connected, FastEthernet0/1
     110.0.0.0/24 is subnetted, 1 subnets
C       110.1.1.0 is directly connected, FastEthernet0/0
     111.0.0.0/24 is subnetted, 1 subnets
C       111.1.1.0 is directly connected, FastEthernet2/0
     10.0.0.0/24 is subnetted, 1 subnets
B       10.1.1.0 [20/0] via 111.1.1.1, 00:06:58
     150.1.0.0/24 is subnetted, 1 subnets
B       150.1.1.0 [200/0] via 110.1.1.1, 00:07:00
     120.0.0.0/24 is subnetted, 1 subnets
C       120.1.1.0 is directly connected, FastEthernet1/0

INTERNAL3(config)#do sh ip route
Gateway of last resort is not set

     140.1.0.0/24 is subnetted, 1 subnets
C       140.1.1.0 is directly connected, FastEthernet0/1
     114.0.0.0/24 is subnetted, 1 subnets
C       114.1.1.0 is directly connected, FastEthernet1/0
     113.0.0.0/24 is subnetted, 1 subnets
C       113.1.1.0 is directly connected, FastEthernet2/0
     130.1.0.0/24 is subnetted, 1 subnets
C       130.1.1.0 is directly connected, FastEthernet0/0
     40.0.0.0/24 is subnetted, 1 subnets
B       40.1.1.0 [20/0] via 114.1.1.2, 00:06:36
     150.1.0.0/24 is subnetted, 1 subnets
B       150.1.1.0 [200/0] via 130.1.1.1, 00:06:38
     30.0.0.0/24 is subnetted, 1 subnets
B       30.1.1.0 [20/0] via 113.1.1.1, 00:06:40


   INTERNAL4(config)#do sh ip route
    Gateway of last resort is not set

         140.1.0.0/24 is subnetted, 1 subnets
    C       140.1.1.0 is directly connected, FastEthernet0/1
         114.0.0.0/24 is subnetted, 1 subnets
    B       114.1.1.0 [200/0] via 140.1.1.1, 00:12:39
         20.0.0.0/24 is subnetted, 1 subnets
    B       20.1.1.0 [200/0] via 112.1.1.2, 00:12:33

         40.0.0.0/24 is subnetted, 1 subnets
    B       40.1.1.0 [200/0] via 114.1.1.2, 00:12:41
         10.0.0.0/24 is subnetted, 1 subnets
    B       10.1.1.0 [200/0] via 111.1.1.1, 00:12:39

         30.0.0.0/24 is subnetted, 1 subnets
    B       30.1.1.0 [200/0] via 113.1.1.1, 00:12:36

[ONLY RELEVANT CONFIGURATION DISPLAYED FOR INTERNAL4]

INTERNAL2#sh run | s bgp
router bgp 64100
 no bgp default ipv4-unicast
 bgp log-neighbor-changes
 neighbor 110.1.1.1 remote-as 64100
 neighbor 111.1.1.1 remote-as 64001
 neighbor 112.1.1.2 remote-as 64002
 neighbor 120.1.1.2 remote-as 64100
 !
 address-family ipv4
  neighbor 110.1.1.1 activate
  neighbor 111.1.1.1 activate
  neighbor 112.1.1.2 activate
  neighbor 120.1.1.2 activate
  no auto-summary
  no synchronization
  network 110.1.1.0 mask 255.255.255.0
  network 111.1.1.0 mask 255.255.255.0
  network 112.1.1.0 mask 255.255.255.0
  network 120.1.1.0 mask 255.255.255.0
 exit-address-family

INTERNAL4#sh run | s bgp
router bgp 64100
 no bgp default ipv4-unicast
 bgp cluster-id 64100
 bgp log-neighbor-changes
 neighbor 120.1.1.1 remote-as 64100
 neighbor 140.1.1.1 remote-as 64100
 neighbor 150.1.1.1 remote-as 64100
 !
 address-family ipv4
  neighbor 120.1.1.1 activate
  neighbor 120.1.1.1 route-reflector-client
  neighbor 140.1.1.1 activate
  neighbor 140.1.1.1 route-reflector-client
  neighbor 150.1.1.1 activate
  no auto-summary
  no synchronization
  network 10.1.1.0 mask 255.255.255.0
  network 20.1.1.0 mask 255.255.255.0
  network 150.1.1.0 mask 255.255.255.0
 exit-address-family

INTERNAL1#sh run | s bgp
router bgp 64100
 no bgp default ipv4-unicast
 bgp cluster-id 64100
 bgp log-neighbor-changes
 neighbor 110.1.1.2 remote-as 64100
 neighbor 130.1.1.2 remote-as 64100
 neighbor 150.1.1.2 remote-as 64100
 !
 address-family ipv4
  neighbor 110.1.1.2 activate
  neighbor 110.1.1.2 route-reflector-client
  neighbor 130.1.1.2 activate
  neighbor 130.1.1.2 route-reflector-client
  neighbor 150.1.1.2 activate
  no auto-summary
  no synchronization
  network 150.1.1.0 mask 255.255.255.0
 exit-address-family

INTERNAL3#sh run | s bgp
router bgp 64100
 no bgp default ipv4-unicast
 bgp log-neighbor-changes
 neighbor 113.1.1.1 remote-as 64003
 neighbor 114.1.1.2 remote-as 64004
 neighbor 130.1.1.1 remote-as 64100
 neighbor 140.1.1.2 remote-as 64100
 !
 address-family ipv4
  neighbor 113.1.1.1 activate
  neighbor 114.1.1.2 activate
  neighbor 130.1.1.1 activate
  neighbor 140.1.1.2 activate
  no auto-summary
  no synchronization
  network 113.1.1.0 mask 255.255.255.0
  network 114.1.1.0 mask 255.255.255.0
  network 130.1.1.0 mask 255.255.255.0
  network 140.1.1.0 mask 255.255.255.0
 exit-address-family
1个回答

仔细检查您的路由的下一跳是否可以通过您的 IGP 到达。这大概就是问题所在。

如果路由器 A有一条192.0.2.0/24 -> 203.0.113.1路由并向路由器 B宣布该路由,但路由器 B不知道如何到达203.0.113.1它,则不会安装 192.0.2.0/24 路由​​。

您是否将 OSPF 或 IS-IS 之类的东西配置为您的 IGP?如果是这样,请尝试 1) 将 ISP4 fa0/0 接口作为被动接口添加到您的 OSPF 配置中,或 2) 使用 next-hop-self 将 BGP 下一跳重写为 INTERNAL3 的环回地址,因为您将其传播到 IBGP邻居。

如果您没有配置 IGP,则需要一个。BGP 并不意味着在没有 IGP(如 OSPF 或 IS-IS)的情况下在 AS 内工作。