当前位置:网站首页>HCIP第八天
HCIP第八天
2022-07-28 07:09:00 【 ᝰꫛꫀꪝ】
1、实验需求
1、使用双点双向重发布
2、所有路由器进行最佳选路
3、存在备份路径,不得出现环路,和路由回馈
4、R1除本身环回外,外加几条环回
172.16.1.0/24 deny
172.16.2.0/24 type 1
172.16.3.0/24 cost 6
172.16.4.0/24 type 1 cost 9
更改如上参数
2、实验拓扑
3、分析过程
1、如拓扑IP地址分配,左边为RIP,右边为OSPF area0
2、2,2,2,2和4.4.4.4环回可能会存在32位掩码和24位掩码的路由,所以进环回接口,将环回接口改为broadcast类型
3、备份路径需将某些路由的Cost值修改在ASBR上进行即可,路由回馈在OSPF中已经解决
4、防止出现环路,将ASBR上面的直连接口重发布入RIP和OSPF区域
5、最后添加路由规则
4、配置内容
R1
[r1]int g 0/0/0
[r1-GigabitEthernet0/0/0]ip address 12.1.1.1 255.255.255.0
[r1-GigabitEthernet0/0/0]int g 0/0/1
[r1-GigabitEthernet0/0/1]ip address 14.1.1.1 255.255.255.0
[r1]int l0
[r1-LoopBack0]ip address 1.1.1.1 255.255.255.0
[r1]int l1
[r1-LoopBack1]ip add 172.16.1.1 24
[r1-LoopBack1]int l2
[r1-LoopBack2]ip add 172.16.2.1 24
[r1-LoopBack2]int l3
[r1-LoopBack3]ip add 172.16.3.1 24
[r1-LoopBack3]int l4
[r1-LoopBack4]ip add 172.16.4.1 24
[r1]rip 1
[r1-rip-1]version 2
[r1-rip-1]network 12.0.0.0
[r1-rip-1]network 1.0.0.0
[r1-rip-1]network 14.0.0.0
[r1-rip-1]network 172.16.0.0
[r1]ip ip-prefix 23 permit 23.1.1.0 24
[r1]int g 0/0/1
[r1-GigabitEthernet0/0/1]rip metricin ip-prefix 23 2
[r1]ip ip-prefix 4 permit 4.4.4.0 24
[r1]ip ip-prefix 43 permit 43.1.1.0 24
[r1]int g 0/0/0
[r1-GigabitEthernet0/0/0]rip metricin ip-prefix 4 2
[r1-GigabitEthernet0/0/0]rip metricin ip-prefix 43 2
R2
[r2]int g 0/0/0
[r2-GigabitEthernet0/0/0]ip address 12.1.1.2
255.255.255.0
[r2-GigabitEthernet0/0/0]int g 0/0/1
[r2-GigabitEthernet0/0/1]ip address 23.1.1.2 255.255.255.0
[r2]int l0
[r2-LoopBack0]ip address 2.2.2.2 255.255.255.0
[r2-LoopBack0]ospf network-type broadcast
[r2]ospf 1
[r2-ospf-1]area 0
[r2-ospf-1-area-0.0.0.0]network 23.1.1.0 0.0.0.255
[r2]ospf 1
[r2-ospf-1] import-route direct
[r2-ospf-1] import-route rip 1
[r2]rip 1
[r2-rip-1] version 2
[r2-rip-1] network 12.0.0.0
[r2-rip-1] network 2.0.0.0
[r2-rip-1] import-route direct
[r2-rip-1] import-route ospf 1
[r2]ip ip-prefix 5 permit 4.4.4.0 24
[r2]ip ip-prefix 6 permit 43.1.1.0 24
[r2]ip ip-prefix 1 permit 172.16.1.0 24
[r2]ip ip-prefix 2 permit 172.16.2.0 24
[r2]ip ip-prefix 3 permit 172.16.3.0 24
[r2]ip ip-prefix 4 permit 172.16.4.0 24
[r2]route-policy haha deny node 10
[r2-route-policy]if-match ip-prefix 1
[r2]route-policy haha permit node 20
[r2-route-policy]if-match ip-prefix 2
[r2-route-policy]apply cost-type type-1
[r2]route-policy haha permit node 30
[r2-route-policy]if-match ip-prefix 3
[r2-route-policy]apply cost 6
[r2]route-policy haha permit node 40
[r2-route-policy]if-match ip-prefix 4
[r2-route-policy]apply cost 9
[r2-route-policy]apply cost-type type-1
[r2]route-policy haha permit node 50
[r2]route-policy haha permit node 15
[r2-route-policy]if-match ip-prefix 5
[r2-route-policy]apply cost-type type-1
[r2]route-policy haha permit node 25
[r2-route-policy]if-match ip-prefix 6
[r2-route-policy]apply cost-type type-1
[r2]ospf 1
[r2-ospf-1]import-route rip 1 route-policy haha
R3
[r3]ospf 1
[r3-ospf-1]area 0
[r3-ospf-1-area-0.0.0.0] network 3.3.3.0 0.0.0.255
[r3-ospf-1-area-0.0.0.0] network 23.1.1.0 0.0.0.255
[r3-ospf-1-area-0.0.0.0] network 43.1.1.0 0.0.0.255
[r3]int g 0/0/0
[r3-GigabitEthernet0/0/0]ip address 43.1.1.3 255.255.255.0
[r3-GigabitEthernet0/0/0]int g 0/0/1
[r3-GigabitEthernet0/0/1]ip address 23.1.1.3 255.255.255.0
R4
[r4]int g 0/0/0
[r4-GigabitEthernet0/0/0]ip address 14.1.1.4 255.255.255.0
[r4-GigabitEthernet0/0/0]int g 0/0/1
[r4-GigabitEthernet0/0/1] ip address 43.1.1.4 255.255.255.0
[r4-GigabitEthernet0/0/1]int l0
[r4-LoopBack0]ip address 4.4.4.4 255.255.255.0
[r4-LoopBack0]ospf network-type broadcast
[r4]rip 1
[r4-rip-1]version 2
[r4-rip-1]network 14.0.0.0
[r4-rip-1]import-route direct
[r4-rip-1]import-route ospf 1
[r4]ip ip-prefix 5 permit 23.1.1.0 24
[r4]ip ip-prefix 6 permit 2.2.2.0 24
[r4]ip ip-prefix 1 permit 172.16.1.0 24
[r4]ip ip-prefix 2 permit 172.16.2.0 24
[r4]ip ip-prefix 3 permit 172.16.3.0 24
[r4]ip ip-prefix 4 permit 172.16.4.0 24
[r4]route-policy haha deny node 10
[r4-route-policy]if-match ip-prefix 1
[r4]route-policy haha permit node 20
[r4-route-policy]if-match ip-prefix 2
[r4-route-policy]apply cost-type type-1
[r4]route-policy haha permit node 30
[r4-route-policy]if-match ip-prefix 3
[r4-route-policy]apply cost 6
[r4]route-policy haha permit node 40
[r4-route-policy]if-match ip-prefix 4
[r4-route-policy]apply cost 9
[r4-route-policy]apply cost-type type-1
[r4]route-policy haha permit node 50
[r4]route-policy haha permit node 15
[r4-route-policy]if-match ip-prefix 5
[r4-route-policy]apply cost-type type-1
[r4]route-policy haha permit node 25
[r4-route-policy]if-match ip-prefix 6
[r4-route-policy]apply cost-type type-1
[r4]ospf 1
[r4-ospf-1]import-route rip 1 route-policy haha
5、结果验证
双向重发布
R1通过RIP学到的路由
R1去2.2.2.2下一跳为12.1.1.2
R3通过OSPF学到的路由
R3去4.4.4.4下一跳为43.1.1.4
R3学到的R1的路由
边栏推荐
- Use of namespaces
- 机器学习如何做到疫情可视化——疫情数据分析与预测实战
- UE4 engine customizes screenpass and MRT output
- leetcode/排序数组中两个数字之和
- Maximum product of leetcode/ word length
- 单片机IO口控制12V电压通断,MOS和三极管电路
- 半桥BUCK电路—记录篇
- Understand the propagation process of EMI electromagnetic interference through five diagrams - the influence of square wave steepness on high-frequency components, the spectrum graph from time sequenc
- pyspark更改列顺序存入iceberg数据库
- [book club issue 13] Chapter 1 multimedia processing tools ffmpeg tools
猜你喜欢
随机推荐
Half bridge buck circuit - record
[book club issue 13] Chapter 1 multimedia processing tools ffmpeg tools
How to configure phpunit under window
opencv+paddle orc 识别图片提取表格信息
招贤纳士,GBASE高端人才招募进行中
微服务架构 Sentinel 的服务限流及熔断
Unity中队列(Queue)的简单使用
PHPUnit在Window下如何配置
Hcip --- LDP and MPLS Technology (detailed explanation)
Creation of status bar (29)
How to build the protection system of class protection technology of 2022 series of ISO compliance (Part I)
【软考软件评测师】2013综合知识历年真题
Export SQL server query results to excel table
Mysql-怎么添加用户和设置权限?
How CI framework integrates Smarty templates
[Qt5] QT small software release
模型预测控制(MPC)解析(九):二次规划的数值解(下)
5张图告诉你:同样是职场人,差距怎么这么大?
PHP基础知识 - PHP 使用 PDO
Feign call












