CCNP-16 OSPF试验12

试验拓扑:

试验要求:R2 R3起OSPF,R1配置静态路由,在R2上配置缺省路由。

试验目的:掌握OSPF缺省路由的配置方法。

试验配置:
R1:
R1(config)#int s1/0
R1(config-if)#ip add 199.99.1.1 255.255.255.0
R1(config-if)#no shu
R1(config-if)#exit
R1(config)#int loop0
R1(config-if)#ip add 100.100.100.100 255.255.255.0
R1(config-if)#exit
R1(config)#ip route 0.0.0.0 0.0.0.0 199.99.1.2
R1(config)#end
R2:
R2(config)#int s1/0
R2(config-if)#ip add 199.99.1.2 255.255.255.0
R2(config-if)#clock rate 64000
R2(config-if)#no shu
R2(config-if)#exit
R2(config)#int s1/1
R2(config-if)#ip add 199.99.2.1 255.255.255.0
R2(config-if)#clock rate 64000
R2(config-if)#no shu
R2(config-if)#exit
R2(config)#int loop0
R2(config-if)#ip add 1.1.1.1 255.255.255.0
R2(config-if)#exit
R2(config)#router ospf 100
R2(config-router)#router-id 1.1.1.1
R2(config-router)#network 199.99.2.0 0.0.0.255 area 0
R2(config-router)#exit
R3:
R3(config)#int s1/0
R3(config-if)#ip add 199.99.2.2 255.255.255.0
R3(config-if)#no shu
R3(config-if)#exit
R3(config)#int loop0
R3(config-if)#ip add 2.2.2.2 255.255.255.0
R3(config-if)#exit
R3(config)#router ospf 100
R3(config-router)#router-id 2.2.2.2
R3(config-router)#network 199.99.2.0 0.0.0.255 area 0
R3(config-router)#exit
基本配置完成,下面查看路由表:
R1#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route
Gateway of last resort is 199.99.1.2 to network 0.0.0.0
C    199.99.1.0/24 is directly connected, Serial1/0
C    100.100.100.0/24 is directly connected, Loopback0
S*   0.0.0.0/0 [1/0] via 199.99.1.2
R1上配置了一条缺省路由,R2和R3都没有到达100.100.100.0/24的路由,如果想让R3能够ping通R1的loopback接口,应该怎么办?有一种解决方法是在R2上配置一条静态路由,然后再把这条静态路由作为缺省路由向区域内洪泛。例如:
R2(config)#router ospf 100
R2(config-router)#default-information originate
R2(config-router)#exit
R2(config)#ip route 0.0.0.0 0.0.0.0 199.99.1.1
好了,特别注意:如果配置default-information originate时没有带always选项,那么路由表里必须有一条静态路由与之相对!下面在R3上查看路由表:
R3#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route
Gateway of last resort is 199.99.2.1 to network 0.0.0.0
2.0.0.0/24 is subnetted, 1 subnets
C       2.2.2.0 is directly connected, Loopback0
C    199.99.2.0/24 is directly connected, Serial1/0
O*E2 0.0.0.0/0 [110/1] via 199.99.2.1, 00:00:00, Serial1/0
看到了最后有一条O*E2缺省路由,外部路由的缺省路由一般是以O*E2的形势泛洪的。Ping测试一下:
R3#ping 100.100.100.100
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 100.100.100.100, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 144/164/192 ms
通了,测试成功!
下面介绍缺省路由中带always选项的配置,带不带always选项的区别就是需不需要路由表里有与之相对应的路由:
R2(config)#router ospf 100
R2(config-router)#default-information originate always
R2(config-router)#exit
这样配置完成后,在R3上查看路由表:
R3#show ip route
Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route
Gateway of last resort is 199.99.2.1 to network 0.0.0.0
2.0.0.0/24 is subnetted, 1 subnets
C       2.2.2.0 is directly connected, Loopback0
C    199.99.2.0/24 is directly connected, Serial1/0
O*E2 0.0.0.0/0 [110/1] via 199.99.2.1, 00:00:01, Serial1/0
发现同样学到了O*E2路由,ping测试一下:
R3#ping 100.100.100.100
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 100.100.100.100, timeout is 2 seconds:
U.U.U
Success rate is 0 percent (0/5)
出现了不可达提示,为什么呢? 因为我把到100.100.100.100的数据包交给我的缺省网关199.99.2.1后,但是缺省网关并不知道怎么到达100.100.100.100,所以返回不可达提示,我们在R2上配置一跳到100.100.100.100的静态路由就可以了:
R2(config)#ip route 100.100.100.0 255.255.255.0 199.99.1.1
好了,再在R3上进行ping测试:
R3#ping 100.100.100.100
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 100.100.100.100, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 240/277/308 ms

通了!

实验总结:掌握OSPF缺省路由的配置方法,并且掌握不带always选项和带always选项的差别!
本文转自loveme2351CTO博客,原文链接:http://blog.51cto.com/loveme23/47278 ,如需转载请自行联系原作者

CCNP-16 OSPF试验12(BSCI)相关推荐

  1. CCNP-17 OSPF试验13(BSCI)

    CCNP-17 OSPF试验13 实验拓扑: 试验要求:1 R1 R2起OSPF,配置R1 R2接口明文验证:           2 R1 R2起OSPF,配置R1 R2接口密文验证:        ...

  2. CCNP-2 EIGRP试验2(BSCI)

    CCNP-2 EIGRP试验2 实验拓扑: 试验要求:1-R1到R4全部起EIGRP路由协议,配置bandwidth,观察EIGRP的等价负载均衡和非等价负载均衡. 试验目的:掌握EIGRP等价负载均 ...

  3. 构建LAMP平台(一)(软件版本:httpd-2.4.16,php-5.6.12,mysql-5.6.26)

    最近在学习LAMP,想把学到的东西写一遍.话不多说,直奔主题好啦. 我构建平台所用到的软件都是目前最新版本,另外我用的linux发行版是RHEL6,下面我将分步骤依次搭建httpd服务器,MySQL服 ...

  4. CCNP知识点总结——OSPF

    1.OSPF介绍 OSPF(Open Shortest Path First,开放最短路径优先)是一种链路状态路由协议,无路由循环(全局拓扑),"开放"意味着非私有的.每一台路由器 ...

  5. CCNP路由实验之十一 IPv6 (8月5号账号被盗,乱发博文深表抱歉,感谢客服帮忙取回密码)

                                          CCNP路由实验之十一 IPv6 IPv4是互联网协议(InternetProtocol,IP)的第四版,也是第一个被广泛使 ...

  6. CCNP认证更攺通知

    目前CCNP考试 新版CCNP考试 642-801 BSCI 642-901 BSCI 642-811 BCMSN 642-812 BCMSN 642-831 BCRAN 642-825 ISCW 6 ...

  7. 视频教程-CCNP 思科认证网络工程师(美女讲师版)-思科认证

    CCNP 思科认证网络工程师(美女讲师版) 思科认证互联网讲师 ISP CCIE# 23996 思科认证讲师 CCSI# 34201 六年IT网络行业教学经验,熟悉网络工程相关业务的工作规范与应用需求 ...

  8. OSPF 提升 一 ----基础

    ospf  ccnp内容 一  link-state protocols      IGP   开放式的最短路径优先协议     公有协议 支持中到大型的网络    spf算法 链路状态协议 1.传送 ...

  9. OSPF路由聚合实验(详细)

    理论准备: 利用abr-summary 过滤区域内的路由,对区域类型没有要求. 利用asbr-summary过滤区域内的外部路由,需要在区域内部的ASBR上配置,当ASBR很多时,配置比较复杂. 利用 ...

最新文章

  1. linux:Ubuntu入门基础
  2. R3LIVE:一个实时鲁棒、带有RGB颜色信息的激光雷达-惯性-视觉紧耦合系统(香港大学)...
  3. 再度剖析AD账户新旧密码同时可用的问题
  4. 开源android豆瓣电影阅读器
  5. 一文搞懂 Java 线程中断
  6. 为什么觉得今年工作特别难找?
  7. ewebeditor 路径
  8. lvds传输距离标准_电平标准整理
  9. Java菜鸟教程怎么用_菜鸟教程 Java 学习笔记 (基础教程)
  10. 手把手教你学DSP:基于TMS320C55x
  11. 菜单栏、工具栏、状态栏
  12. MAX3485芯片资料整理
  13. mysql chunk_【MySQL参数】-innodb_buffer_pool_chunk_size
  14. -webkit-border-radius和-moz-border-radius分析
  15. 名帖344 怀素 草书《佛说四十二章经》
  16. Python基础学习第八天
  17. 将PPT文件转换成HTML格式
  18. 非root手机如何脱壳?
  19. 一张图生成定制版二次元人脸头像,还能“模仿”你的表情
  20. -CSS3长度单位rem、vh、vw、vmin、vmax、ex、ch

热门文章

  1. [持续更新][小工具]计算器
  2. 要如何努力,才干成为非常厉害的人?!
  3. 多线程——实现Callable接口
  4. BZOJ3823 : 定情信物
  5. Strongswan — 常用配置说明
  6. 移动通信网络协议 — GTP 协议
  7. Openstack API 类型 REST 风格
  8. C语言便于调试的宏定义 __FILE__、__FUNCTION__、__LINE__、__VA_ARGS__ 参数使用
  9. Internet Explorer 已停止工作 解决办法
  10. 颜色传感器TCS230的使用