本帖最后由 Jeff. 于 2010-12-30 14:05 编辑
回复 17 # kingair 的帖子
这样,按照你的环境,你把bgp 的同步关闭,然后再R3上ospf里面通告R3的loopback 0 3.3.3.3.3 然后router-id设置为3.3.3.3 ,然后再BGP下通告3.3.3.3 ,然后router-id设置为4.4.4.4 , 然后R1---R3建立IBGP的邻居关系,R1,R3关闭下bgp同步, 这个时候你会发现 R1中show ip bgp学习到3.3.3.3是一条不优的路径 原因是:R3上面的bgp router-id 和OSPF router-id不一致,R1认为从R3的bgp学习到的3.3.3.3 必须从IGP学习到也就是OSPF,如果OSPF的router-id和BGP的router-id不一样,R1会认为没有IGP路由,故BGP路由不可用~(同步规则)
BGP Router-ID 和OSPF ROUTER-ID 不一样的时候显示:
R1#sh ip bgp
BGP table version is 1, local router ID is 1.1.1.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
r RIB-failure, S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
* i3.3.3.3/32 3.3.3.3 0 100 0 i
R1#
R1#sh ip bg 3.3.3.3
BGP routing table entry for 3.3.3.3/32, version 0
Paths: (1 available, no best path)
Not advertised to any peer
Local
3.3.3.3 (metric 129) from 3.3.3.3 (4.4.4.4)
Origin IGP, metric 0, localpref 100, valid, internal, not synchronized
R1#
BGP Router-ID 和OSPF ROUTER-ID 一样的时候显示:
R1#sh ip bgp
BGP table version is 3, local router ID is 1.1.1.1
Status codes: s suppressed, d damped, h history, * valid, > best, i - internal,
r RIB-failure, S Stale
Origin codes: i - IGP, e - EGP, ? - incomplete
Network Next Hop Metric LocPrf Weight Path
r>i3.3.3.3/32 3.3.3.3 0 100 0 i
R1#
R1#sh ip bg 3.3.3.3
BGP routing table entry for 3.3.3.3/32, version 3
Paths: (1 available, best #1, table Default-IP-Routing-Table, RIB-failure(17))
Flag: 0x820
Not advertised to any peer
Local
3.3.3.3 (metric 129) from 3.3.3.3 (3.3.3.3)
Origin IGP, metric 0, localpref 100, valid, internal, synchronized, best
R1#
|