1.配置地址
2.啟動(dòng)ospf協(xié)議
3.啟動(dòng)rip協(xié)議
4.將PC1 的路由引入OSPF中
[R1]ospf 1
[R1-ospf-1]import-route direct
5.將 PC2重發(fā)布到RIP中
[R4]rip
[R4-rip-1]import-route direct
6.在R2 和R3上進(jìn)行雙點(diǎn)雙向重發(fā)布
[R3]rip
[R3-rip-1]import-route ospf 1
[R3]ospf 1
[R3-ospf-1]import-route rip u
[R2]rip
[R2-rip-1]import-route ospf 1
[R2]ospf 1
[R2-ospf-1]import-route rip
R1路由表
7.在R3的路由表中 存在一個(gè)次優(yōu)路由
(1)第一種解決辦法
[R2]ip ip-prefix pc1 permit 10.1.1.0 24
[R2]route-policy pc1 permit node 10
Info: New Sequence of this List.
[R2-route-policy]if-match ip-prefix pc1
[R2-route-policy]apply preference 90
[R2-route-policy]qu
[R2]route-policy pc1 permit node 20
Info: New Sequence of this List.
[R2]ospf 1
[R2-ospf-1]preference route-policy pc1
[R2-ospf-1]qu
[R3]ip ip-prefix pc1 permit 10.1.1.0 24
[R3]route-policy pc1 permit node 10
Info: New Sequence of this List.
[R3-route-policy]if-match ip-prefix pc1
[R3-route-policy]apply preference 160
[R3-route-policy]qu
[R3]route-policy pc1 permit node 20
Info: New Sequence of this List.
[R3-route-policy]qu
[R3]rip 1
[R3-rip-1]preference route-policy pc1
反應(yīng)較慢 可以通過(guò)shutdown 接口來(lái)查看
R2上配置是為了以后R2故障后出現(xiàn)該次優(yōu)路由
第二種方法:
[R3]ip ip-prefix xwl deny 10.1.1.0 24
[R3]ip ip-prefix xwl permit 0.0.0.0 0 less-equal 32
[R3-rip-1]filter-policy ip-prefix xwl import GigabitEthernet 0/0/1 學(xué)習(xí)到該次優(yōu)路由的接口
第三種方法:
[R1]ospf 1
[R1-ospf-1]
[R1-ospf-1]import-route direct ?
cost Set cost
route-policy Route policy
tag Specify route tag
type Metric type of the imported external routes
Please press ENTER to execute command
[R1-ospf-1]import-route direct tag 111
然后在R2 和R3上根據(jù)需求采取第一或第二種辦法
[R3]route-policy tag permit node 10
Info: New Sequence of this List.
[R3-route-policy]if-match tag 111
[R3-route-policy]apply preference 90
[R3-route-policy]qu
[R3]route-policy pc1 permit node 20
Info: New Sequence of this List.
[R3-route-policy]qu
[R2]ospf 1
[R2-ospf-1]preference route-policy tag
[R2-ospf-1]qu
-
路由
+關(guān)注
關(guān)注
0文章
278瀏覽量
41844 -
OSPF
+關(guān)注
關(guān)注
0文章
80瀏覽量
14887
原文標(biāo)題:路由協(xié)議&OSPF中雙點(diǎn)雙向重發(fā)布解決路由引入問(wèn)題(華為)
文章出處:【微信號(hào):網(wǎng)絡(luò)技術(shù)干貨圈,微信公眾號(hào):網(wǎng)絡(luò)技術(shù)干貨圈】歡迎添加關(guān)注!文章轉(zhuǎn)載請(qǐng)注明出處。
發(fā)布評(píng)論請(qǐng)先 登錄
相關(guān)推薦
評(píng)論