HCIP---OSPF综合实验

目录

1、IP地址划分

2、配置IP地址

3、配置缺省路由

4、访问R4的环回需要配置NAT

5、MGRE环境配置

6、配置OSPF,重发布

7、汇总、空接口防环路由

8、特殊区域

9、加快收敛(更改hello时间),保障更新安全(手工认证)

10、实验结果


 

1、IP地址划分

172.16.0.0/16

172.16.0.0/19

172.16.32.0/19

172.16.64.0/19

172.16.96.0/19

172.16.128.0/19

172.16.160.0/19

172.16.192.0/19

172.16.224.0/19

area 1

172.16.0.0/19

172.16.0.0/21

172.16.8.0/21

172.16.16.0/21

172.16.24.0/21

area 0

172.16.32.0/19

172.16.32.0/21

172.16.40.0/21

172.16.48.0/21

172.16.56.0/21

area 2

172.16.64.0/19

172.16.64.0/21

172.16.72.0/21

172.16.80.0/21

172.16.88.0/21

area 3

172.16.96.0/19

172.16.96.0/21

172.16.104.0/21

172.16.112.0/21

172.16.120.0/21

area 4

172.16.128.0/19

172.16.128.0/21

172.16.136.0/21

172.16.144.0/21

172.16.152.0/21

RIP

172.16.160.0/19

172.16.160.0/21

172.16.168.0/21

172.16.176.0/21

172.16.184.0/21

2、配置IP地址

R1

 

R2

R3

 

R4

 

R5

 

R6

 

R7

 

R8

 

R9

 

R10

 

R11

 

R12

 

3、配置缺省路由

[R1]ip route-static 0.0.0.0 0 172.16.0.3

[R2]ip route-static 0.0.0.0 0 172.16.0.3

[R3]ip route-static 0.0.0.0 0 12.1.1.1

[R5]ip route-static 0.0.0.0 0 13.1.1.1

[R6]ip route-static 0.0.0.0 0 14.1.1.1

[R7]ip route-static 0.0.0.0 0 16.1.1.1

[R8]ip route-static 0.0.0.0 0 172.16.96.1

[R9]ip route-static 0.0.0.0 0 172.16.104.1

[R10]ip route-static 0.0.0.0 0 172.16.128.1

[R11]ip route-static 0.0.0.0 0 172.16.64.1

[R12]ip route-static 0.0.0.0 0 172.16.80.1

4、访问R4的环回需要配置NAT

[R3]acl 2000

[R3-acl-basic-2000]rule 1 permit source any

[R3]interface  s4/0/0

[R3-Serial4/0/0]nat outbound 2000

[R5]acl 2000

[R5-acl-basic-2000]rule 1 permit source any

[R5]interface  s4/0/0

[R5-Serial4/0/0]nat outbound 2000

[R6]acl 2000

[R6-acl-basic-2000]rule 1 permit source any

[R6]in s4/0/0

[R6-Serial4/0/0]nat outbound 2000

[R7]acl 2000

[R7-acl-basic-2000]rule 1 permit source any

[R7]in s4/0/0

[R7-Serial4/0/0]nat outbound 2000

5、MGRE环境配置

R3中心站点配置

[R3]interface Tunnel 0/0/0

[R3-Tunnel0/0/0]ip ad 172.16.32.1 21

[R3-Tunnel0/0/0]tunnel-protocol gre p2mp

[R3-Tunnel0/0/0]source 12.1.1.2

[R3-Tunnel0/0/0]nhrp entry multicast dynamic

[R3-Tunnel0/0/0]nhrp network-id 100

分支站点配置

R5

[R5]interface Tunnel 0/0/0

[R5-Tunnel0/0/0]ip address 172.16.32.2 21

[R5-Tunnel0/0/0]tunnel-protocol gre p2mp

[R5-Tunnel0/0/0]source s4/0/0

[R5-Tunnel0/0/0]nhrp network-id 100

[R5-Tunnel0/0/0]nhrp entry 172.16.32.1 12.1.1.2 register

R6

[R6]in t0/0/0

[R6-Tunnel0/0/0]ip ad 172.16.32.3 21

[R6-Tunnel0/0/0]tunnel-protocol gre p2mp

[R6-Tunnel0/0/0]source Serial 4/0/0

[R6-Tunnel0/0/0]nhrp network-id 100

[R6-Tunnel0/0/0]nhrp entry 172.16.32.1 12.1.1.2 register

R7

[R7]in t0/0/0

[R7-Tunnel0/0/0]ip ad 172.16.32.4 21

[R7-Tunnel0/0/0]tunnel-protocol gre p2mp

[R7-Tunnel0/0/0]source Serial 4/0/0

[R7-Tunnel0/0/0]nhrp network-id 100

[R7-Tunnel0/0/0]nhrp entry 172.16.32.1 12.1.1.2 register

R3上注册结果

6、配置OSPF,重发布

R1

[R1]ospf 1 router-id 1.1.1.1

[R1-ospf-1]area 1

[R1-ospf-1-area-0.0.0.1]network 172.16.0.0 0.0.7.255  

[R1-ospf-1-area-0.0.0.1]network 172.16.8.0 0.0.7.255

R2

[R2]ospf router-id 2.2.2.2

[R2-ospf-1]area 1

[R2-ospf-1-area-0.0.0.1]network 172.16.0.0 0.0.7.255

[R2-ospf-1-area-0.0.0.1]network 172.16.16.0 0.0.7.255

R3

[R3]ospf router-id 3.3.3.3

[R3-ospf-1]area 1

[R3-ospf-1-area-0.0.0.1]network 172.16.0.0 0.0.7.255

[R3-ospf-1-area-0.0.0.1]network 172.16.24.0 0.0.7.255

[R3-ospf-1]area 0

[R3-ospf-1-area-0.0.0.0]network 172.16.32.0 0.0.7.255

R5

[R5]ospf 1 router-id 5.5.5.5

[R5-ospf-1]area 0

[R5-ospf-1-area-0.0.0.0]network 172.16.32.0 0.0.7.255

[R5-ospf-1-area-0.0.0.0]network 172.16.40.0 0.0.7.255

R6

[R6]ospf 1 router-id 6.6.6.6

[R6-ospf-1]area 0

[R6-ospf-1-area-0.0.0.0]network 172.16.32.0 0.0.7.255

[R6-ospf-1-area-0.0.0.0]network 172.16.48.0 0.0.7.255

[R6-ospf-1]area 2

[R6-ospf-1-area-0.0.0.2]network 172.16.64.0 0.0.7.255

R7

[R7]ospf 1 router-id 7.7.7.7

[R7-ospf-1]area 0

[R7-ospf-1-area-0.0.0.0]network 172.16.32.0 0.0.7.255

[R7-ospf-1-area-0.0.0.0]network 172.16.56.0 0.0.7.255

[R7-ospf-1]area 3

[R7-ospf-1-area-0.0.0.3]network 172.16.96.0 0.0.7.255

R8

[R8]ospf 1 router-id 8.8.8.8

[R8-ospf-1]area 3

[R8-ospf-1-area-0.0.0.3]network 172.16.96.0 0.0.7.255

[R8-ospf-1-area-0.0.0.3]network 172.16.112.0 0.0.7.255

[R8-ospf-1-area-0.0.0.3]network 172.16.104.0 0.0.7.255

R9

[R9]ospf 1 router-id 9.9.9.9

[R9-ospf-1]area 3

[R9-ospf-1-area-0.0.0.3]network 172.16.104.0 0.0.7.255

因为area 4 区域为不规则区域,要进行双向重发布

[R9]ospf 2 router-id 9.9.9.9

[R9-ospf-2]area 0

[R9-ospf-2-area-0.0.0.0]network 172.16.128.0 0.0.7.255

[R9-ospf-2-area-0.0.0.0]network 172.16.136.0 0.0.7.255

[R9]ospf 1

[R9-ospf-1]import-route ospf 2

[R9]ospf 2

[R9-ospf-2]import-route ospf 1

R10

[R10]ospf 2 router-id 10.10.10.10

[R10-ospf-2]area 0

[R10-ospf-2-area-0.0.0.0]network 172.16.128.0 0.0.7.255

[R10-ospf-2-area-0.0.0.0]network 172.16.144.0 0.0.7.255

R11

[R11]ospf 1 router-id 11.11.11.11

[R11-ospf-1]area 2

[R11-ospf-1-area-0.0.0.2]network 172.16.64.0 0.0.7.255

[R11-ospf-1-area-0.0.0.2]network 172.16.72.0 0.0.7.255

[R11-ospf-1-area-0.0.0.2]network 172.16.80.0 0.0.7.255

R12

[R12]ospf 1 router-id 12.12.12.12

[R12-ospf-1]area 2

[R12-ospf-1-area-0.0.0.2]network 172.16.80.0 0.0.7.255

环回用RIP

[R12]rip 1

[R12-rip-1]version 2

[R12-rip-1]network 172.16.0.0

再进行双向重发布

[R12]ospf 1

[R12-ospf-1]import-route rip 1

[R12]rip 1

[R12-rip-1]import-route ospf 1

修改R3-R5-R6-R7的Tunnel接口类型为Broadcast

[R3-Tunnel0/0/0]ospf network-type broadcast

[R5-Tunnel0/0/0]ospf network-type broadcast

[R6-Tunnel0/0/0]ospf network-type broadcast

[R7-Tunnel0/0/0]ospf network-type broadcast

修改R5-R6-R7的接口优先级,不让其参与DR/BDR选举

[R5-Tunnel0/0/0]ospf dr-priority 0

[R6-Tunnel0/0/0]ospf dr-priority 0

[R7-Tunnel0/0/0]ospf dr-priority 0

在R3可以看到其学到了去所有网段的路

 

7、汇总、空接口防环路由

域间路由汇总

[R3-ospf-1-area-0.0.0.1]abr-summary 172.16.0.0 255.255.224.0

[R3]ip route-static 172.16.0.0 19 NULL 0

[R6-ospf-1-area-0.0.0.2]abr-summary 172.16.64.0 255.255.224.0

[R6]ip route-static 172.16.64.0 19 NULL 0

[R7-ospf-1-area-0.0.0.3]abr-summary 172.16.96.0 255.255.224.0

[R7]ip route-static 172.16.96.0 19 NULL 0

域外路由汇总

[R9-ospf-1]asbr-summary 172.16.128.0 255.255.224.0

[R9]ip route-static 172.16.128.0 19 NULL 0

[R12-ospf-1]asbr-summary 172.16.160.0 255.255.224.0

[R12]ip route-static 172.16.160.0 19 NULL 0

8、特殊区域

末梢区域/完全末梢区域

[R1]ospf 1

[R1-ospf-1]area 1

[R1-ospf-1-area-0.0.0.1]stub

[R2]ospf 1

[R2-ospf-1]area 1

[R2-ospf-1-area-0.0.0.1]stub

[R3]ospf 1

[R3-ospf-1]area 1

[R3-ospf-1-area-0.0.0.1]stub

[R3-ospf-1-area-0.0.0.1]stub no-summary

NSSA/完全NSSA

[R6-ospf-1-area-0.0.0.2]nssa

[R6-ospf-1-area-0.0.0.2]nssa no-summary

[R11-ospf-1-area-0.0.0.2]nssa

[R12-ospf-1-area-0.0.0.2]nssa

[R7-ospf-1-area-0.0.0.3]nssa

[R7-ospf-1-area-0.0.0.3]nssa no-summary

[R8-ospf-1-area-0.0.0.3]nssa

[R9-ospf-1-area-0.0.0.3]nssa

9、加快收敛(更改hello时间),保障更新安全(手工认证)

[R1-GigabitEthernet0/0/0]ospf timer hello 5

[R1-GigabitEthernet0/0/0]ospf authentication-mode md5 1 cipher 123456

[R2-GigabitEthernet0/0/0]ospf timer hello 5

[R2-GigabitEthernet0/0/0]ospf authentication-mode md5 1 cipher 123456

[R3-GigabitEthernet0/0/0]ospf timer hello 5

[R3-GigabitEthernet0/0/0]ospf authentication-mode md5 1 cipher 123456

[R3-Tunnel0/0/0]ospf timer hello 5

[R3-Tunnel0/0/0]ospf authentication-mode md5 1 cipher 123456

[R5-Tunnel0/0/0]ospf timer hello 5

[R5-Tunnel0/0/0]ospf authentication-mode md5 1 cipher 123456

[R6-Tunnel0/0/0]ospf timer hello 5

[R6-Tunnel0/0/0]ospf authentication-mode md5 1 cipher 123456

[R6-Serial4/0/1]ospf timer hello 5

[R6-Serial4/0/1]ospf authentication-mode md5 1 cipher 123456

[R11-Serial4/0/0]ospf timer hello 5

[R11-Serial4/0/0]ospf authentication-mode md5 1 cipher 123456

[R11-Serial4/0/1]ospf timer hello 5

[R11-Serial4/0/1]ospf authentication-mode md5 1 cipher 123456

[R12-Serial4/0/0]ospf timer hello 5

[R12-Serial4/0/0]ospf authentication-mode md5 1 cipher 123456

[R7-Tunnel0/0/0]ospf timer hello 5

[R7-Tunnel0/0/0]ospf authentication-mode md5 1 cipher 123456

[R7-Serial4/0/1]ospf timer hello 5

[R7-Serial4/0/1]ospf authentication-mode md5 1 cipher 123456

[R8-Serial4/0/0]ospf timer hello 5

[R8-Serial4/0/0]ospf authentication-mode md5 1 cipher 123456

[R8-Serial4/0/1]ospf timer hello 5

[R8-Serial4/0/1]ospf authentication-mode md5 1 cipher 123456

[R9-Serial4/0/0]ospf timer hello 5

[R9-Serial4/0/0]ospf authentication-mode md5 1 cipher 123456

[R9-Serial4/0/1]ospf timer hello 5

[R9-Serial4/0/1]ospf authentication-mode md5 1 cipher 123456

[R10-Serial4/0/0]ospf timer hello 5

[R10-Serial4/0/0]ospf authentication-mode md5 1 cipher 123456

10、实验结果

R1的环回ping R12的环回

 

R1的环回ping R5的环回

 

R1的环回ping R10的环回

 

R1的环回ping R4的环回

 

  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
1、课程简介 本课程为华为HCNP进阶级资深网络工程师培训课程,学习课程前请先完成CCNA或HCNA课程学习,或有NA同等水平。本课程为本人在机构授课期间现场录制,视频清晰无水印,语音清晰,授课风格有趣。课程主要介绍思科主流的交换技术与路由技术,学习完本课程后你将具有相应的技能水平,能够对中大型企业网络或校园网络网络架构有更加深入的了解以及各技术所应用场景,清楚技术特点,还能够对中大型企业网或校园网等网络进行设计,维护,故障处理等。在课程最后有综合实验,如果在学习完成后可无需查看资料或课件命令即能完成80%以上的实验需求及功能,则代表你已具有一定的技术水平,可认为你是一名资深级的网络工程师。2、讲师简介 ·         钟海林 | 老钟 | HELY ·         7年IT从业经验,4年网络及安全技术授课经验·         曾负责广州移动DCN网络改造及设计,深圳三诺电子网络改造·         擅长网络技术与安全技术,精通各大厂商网络产品与安全产品·         授课风格风骚有趣,擅长从实践中总结理论知识,不讲废话,直奔主题3、课程目标 掌握思科路由交换技术,包括交换模块的HSRP,MSTP,ARP检测,DHCP检测等技术以及路由技术模块的OSPF,EIGRP,BGP,ISIS协议等。4、课程对象 具有CCNA、HCNA、CCNA认证或具有同等技术水平的人员及其他同级别认证等人员5、课程特色 课程内容精准,知识点精准,不废话,直接干!老师讲课语音清晰,且视频清晰无水印。课程内容没有晦涩难懂的名词及数学公式或逻辑概念等,完全适合零基础,且涉及的知识点通过现实中的一些实例做对比,简化问题。6、课程内容 ·         交换技术:MSTP,HSRP,VRRP,DHCP检测,ARP检测·         路由技术:RIP,OSPF,ISIS,BGP ·         综合实验 7、课程预览 8、了解更多 ·         思科CCNP高级交换课程 https://edu.csdn.net/course/detail/24001·         思科CCNP高级路由课程 https://edu.csdn.net/course/detail/24009·         思科IPS防御系统视频课程 https://edu.csdn.net/course/detail/20392·         思科ASA防火墙视频课程 https://edu.csdn.net/course/detail/20388·         华为防火墙视频课程 https://edu.csdn.net/course/detail/203919、注意事项 ·         本课程仅用于自学,不得用于商业用途·         课程内所讲解技术只能用于模拟环境,若使用在其他环境造成的任何问题本人不负责

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值