我有一个学习BGP的前缀130.130.0.0/24,带有协议下一跳10.0.2.5:
root@r2> show route 130.130.0.0 detail
inet.0: 60 destinations, 61 routes (57 active, 0 holddown, 4 hidden)
130.130.0.0/24 (1 entry, 1 announced)
*BGP Preference: 170/-101
Next hop type: Indirect, Next hop index: 0
Address: 0xd30c210
Next-hop reference count: 6
Source: 10.0.3.4
Next hop type: Router, Next hop index: 0
Next hop: 10.0.4.9 via ge-0/0/3.0, selected
Session Id: 0x0
Next hop: 10.0.4.1 via ge-0/0/6.0
Session Id: 0x0
Protocol next hop: 10.0.2.5
Indirect next hop: 0xba9dd80 1048582 INH Session ID: 0x1aa
State: <Active Int Ext>
Local AS: 65001 Peer AS: 65001
Age: 44:28 Metric2: 20
Validation State: unverified
ORR Generation-ID: 0
Task: BGP_65001.10.0.3.4+179
Announcement bits (2): 0-KRT 5-Resolve tree 4
AS path: (65000) 65222 I
Communities: 65412:200
Accepted
Localpref: 100
Router ID: 10.0.3.4
root@r2>如上所述,10.0.2.5被解析为next-跃点10.0.4.9(selected)和10.0.4.1。但是,show route 10.0.2.5的输出选择一个10.0.4.1作为下一跳:
root@r2> show route 10.0.2.5
inet.0: 60 destinations, 61 routes (57 active, 0 holddown, 4 hidden)
+ = Active Route, - = Last Active, * = Both
10.0.2.4/30 *[IS-IS/15] 1w5d 02:17:27, metric 20
to 10.0.4.9 via ge-0/0/3.0
> to 10.0.4.1 via ge-0/0/6.0
root@r2> show route forwarding-table matching 10.0.2.4/30 table default
Routing table: default.inet
Internet:
Enabled protocols: Bridging,
Destination Type RtRef Next hop Type Index NhRef Netif
10.0.2.4/30 user 0 10.0.4.1 ucst 595 5 ge-0/0/6.0
root@r2>为什么BGP protocol next hop使用与ISIS不同的下一跳地址?
发布于 2020-11-05 16:09:22
为什么BGP协议下一跳使用与ISIS不同的下一跳地址?
因为与130.130.0.0/24相关联的BGP下一跳为10.0.2.5。BGP必须解决该路由的下一跳,正如您指出的那样,这就是IS-IS路由。这就引出了一个问题,那就是如何达到10.0.2.5,也就是通过接口路由10.0.4.9和10.0.4.1。
杰夫惠勒是正确的,为什么你没有看到这两条路线在FIB。假设这是肋骨:
jhead@r3# run show route 1.1.1.1/32 detail
inet.0: 14 destinations, 14 routes (14 active, 0 holddown, 0 hidden)
1.1.1.1/32 (1 entry, 1 announced)
*BGP Preference: 170/-101
Next hop type: Indirect, Next hop index: 0
Address: 0xce31930
Next-hop reference count: 2
Source: 10.10.10.10
Next hop type: Router, Next hop index: 0
Next hop: 172.16.0.14 via ge-0/0/0.0, selected
Session Id: 0x0
Next hop: 172.16.0.18 via ge-0/0/1.0
Session Id: 0x0
Protocol next hop: 10.10.10.10
Indirect next hop: 0xba3e680 1048575 INH Session ID: 0x142
State: <Active Int Ext>
Local AS: 65000 Peer AS: 65000
Age: 13:48 Metric2: 2
Validation State: unverified
Task: BGP_65000.10.10.10.10
Announcement bits (2): 0-KRT 4-Resolve tree 1
AS path: I
Accepted
Localpref: 100
Router ID: 10.10.10.10
jhead@r3# run show route 10.10.10.10
inet.0: 14 destinations, 14 routes (14 active, 0 holddown, 0 hidden)
+ = Active Route, - = Last Active, * = Both
10.10.10.10/32 *[OSPF/10] 00:14:53, metric 2
> to 172.16.0.14 via ge-0/0/0.0
to 172.16.0.18 via ge-0/0/1.0没有负载平衡策略的
jhead@r3# run show route forwarding-table destination 10.10.10.10
Routing table: default.inet
Internet:
Enabled protocols: Bridging,
Destination Type RtRef Next hop Type Index NhRef Netif
10.10.10.10/32 user 1 172.16.0.14 ucst 583 8 ge-0/0/0.0具有负载平衡策略的
jhead@r3# run show route forwarding-table destination 10.10.10.10
Routing table: default.inet
Internet:
Enabled protocols: Bridging,
Destination Type RtRef Next hop Type Index NhRef Netif
10.10.10.10/32 user 1 ulst 1048574 4
172.16.0.14 ucst 583 6 ge-0/0/0.0
172.16.0.18 ucst 584 6 ge-0/0/1.0https://networkengineering.stackexchange.com/questions/70818
复制相似问题