# 14.5OSPF综合实验(认证+缺省路由发布)

实验拓扑及要求

在这里插入图片描述

实验配置

sys
sys AR1
int g0/0/0
ip add 192.168.0.1 24
ospf dr-priority 200 优先级
ospf 1 router-id 1.1.1.1
area 0
net 192.168.0.0 0.0.0.255

sys
sys AR2
int g0/0/0
ip add 192.168.0.2 24
ospf dr-priority 100
ospf 1 router-id 2.2.2.2
area 0 
net 192.168.0.0 0.0.0.255

sys
sys AR3
int g0/0/0
ip add 192.168.0.3 24
ospf 1 router-id 3.3.3.3
area 0
net 192.168.0.0 0.0.0.255
net 34.0.0.0 0.255.255.255
int s4/0/0
ip add 34.0.0.3 8

sys
sys AR6
int g0/0/0
ip add 192.168.0.6 24
ospf 1 router-id 6.6.6.6
area 0 
net 192.168.0.0 0.0.0.255

dis ospf peer brief 看邻居建立状态
dis ospf int g0/0/0 看DR和BDR
dis ip routing-table protocol ospf 路由表协议ospf–开销 下一跳
dis ospf int g0/0/0 s4/0/0
<>reset ospf process 重启进程
down失效
init初始-收到对方hello包,没看到自己
two-way双向通讯-收到hello包,看到自己,形成邻居
exstart交换初始,决定主从关系
exchange-向邻居发送database description
loading LSR和LSU交换
full LSDB同步,形成邻接关系

sys
sys AR4
int g0/0/1
ip add 48.0.0.4 8
int s4/0/1
ip add 34.0.0.4 8
int loopback 4
ip add 4.4.4.4 32
ospf 1 router-id 4.4.4.4
area 0
net 4.4.4.4 0.0.0.0
net 34.0.0.0 0.255.255.255

sys
sys AR8
int g0/0/0
ip add 48.0.0.8 8
q
ip route-static 0.0.0.0 0 48.0.0.4 缺省 
int loopback 8
ip add 8.8.8.8 32

R1 ping 8.8.8.8

缺省路由发布
1.
R4引入(np)48路由-直连
R4
ospf 1
import-route direct
R1dis ip rou pro ospf --48.0.0.0
ping 48.0.0.8

2.静态写入(na)
ip route-static 0.0.0.0 0 48.0.0.4
3.动态发布(na)
R4
ip route-static 0.0.0.0 0 48.0.0.8
default-route-advertise

R1 dis rou pro ospf
0.0.0.0/0 O_ASE 外部路由 优先级150

R4
acl 2000
rule 1 permit
q
int g0/0/1
nat outbound 2000
R1 ping 8.8.8.8

MD5认证配置
1.接口认证
int g0/0/0
ospf authentication-mode md5 1 cipher hwhwhw
2.区域认证
ospf 1
area 0
authentication-mode md5 1(密钥id需要一致) cipher hwhwhw

同时配置,接口优先生效
5个接口4个接口同时配置,先区域,然后删除其中一个

R1-3 R6
int G0/0/0 ospf authenticatio-mode md5 1 cipher 123456

OSPF 1
dis th 查看认证

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值