OSPF综合实验

  • 拓扑图

  • 实验需求

1.整个网络使用192.168.1.0/24.进行地址分配
2.R1、R2、R5上各配置一个环回接口,R1和R2的环回接口可以宣告到OSPF网络
3.设备的RID为每台设备的名称编号(AR1==1.1.1.1)
4.R3与R4之间使用密文认证,密码为:Admin@huawei.com
5.Area 0区域内,R2为DR、R1为BDR
6.全网可达
  • 需求分析

1.子网划分
2.环回接口
3.配置RID
4.手工认证
5.优先级
6.全网通
  • 实验步骤

  • 1.子网划分

192.168.1.0/24--3个网段
192.168.1.00 000000--192.168.1.0/26----192.168.1.63/26
192.168.1.01 000000--192.168.1.64/26---192.168.1.127/26
192.168.1.10 000000--192.168.1.128/26--192.168.1.191/26
192.168.1.11 000000--192.168.1.192/26--192.168.1.255/26

配置网关:
AR1:
192.168.1.2/26
AR2;
192.168.1.3/26
AR3:
192.168.1.1/26
192.168.1.65/26
AR4:
192.168.1.66/26
129.168.1.129/26
AR5:
192.168.1.130/26
  • 2.环回接口

192.168.1.192/26--三个网段
192.168.1.1100 0000--192.168.1.192/28--192.168.1.207/28
192.168.1.1101 0000--192.168.1.208/28--192.168.1.223/28
192.168.1.1110 0000--192.168.1.224/28--192.168.1.239/28
192.168.1.1111 0000--192.168.1.240/28--192.168.1.255/28
AR1环回接口:
192.168.1.193/28
AR2环回接口:
192.168.1.209/28
AR5环回接口:
192.168.1.225/28
  • 3.开启OSPF协议并设置RID

AR1:
  [Huawei]ospf 1 router-id 1.1.1.1
  [Huawei-ospf-1]area 0
  [Huawei-ospf-1-area-0.0.0.0]network 192.168.1.193 0.0.0.0
  [Huawei-ospf-1-area-0.0.0.0]network 192.168.1.2 0.0.0.0
AR2:
  [Huawei]ospf 1 router-id 2.2.2.2
  [Huawei-ospf-1]area 0
  [Huawei-ospf-1-area-0.0.0.0]network 192.168.1.209 0.0.0.0
  [Huawei-ospf-1-area-0.0.0.0]network 192.168.1.3 0.0.0.0
AR3:
  [Huawei]ospf 1 router-id 3.3.3.3
  [Huawei-ospf-1]area 0
  [Huawei-ospf-1-area-0.0.0.0]network 192.168.1.1 0.0.0.0
  [Huawei-ospf-1]area 1
  [Huawei-ospf-1-area-0.0.0.1]network 192.168.1.65 0.0.0.0
AR4:
  [Huawei]ospf 1 router-id 4.4.4.4
  [Huawei-ospf-1]area 1
  [Huawei-ospf-1-area-0.0.0.1]network 192.168.1.66 0.0.0.0
  [Huawei-ospf-1-area-0.0.0.1]network 192.168.1.129 0.0.0.0
AR5:
  [Huawei]ospf 1 router-id 5.5.5.5
  [Huawei-ospf-1]area 1
  [Huawei-ospf-1-area-0.0.0.1]network 192.168.1.130 0.0.0.0
  • 4.手工认证

AR3:
[Huawei]interface g 0/0/1
[Huawei-GigabitEthernet0/0/1]ospf authentication-mode md5 1 cipher Admin@huawei.com
AR4:
[Huawei]interface g 0/0/0
[Huawei-GigabitEthernet0/0/0]ospf authentication-mode md5 1 cipher Admin@huawei.com
  • 5.优先级

1.查看邻居表:
[Huawei]display ospf peer

2.修改AR2优先级为10:
AR2:
[Huawei]interface g 0/0/0
[Huawei-GigabitEthernet0/0/0]ospf dr-priority 10
<Huawei>reset ospf process 
<Huawei>reset ospf process 
AR1:
<Huawei>reset ospf process
AR3:
<Huawei>reset ospf process

3.查看邻接表:
[Huawei]display ospf peer

  • 6.全网可达

以AR1为例:
[Huawei]ping -a 192.168.1.193 192.168.1.209
  PING 192.168.1.209: 56  data bytes, press CTRL_C to break
    Reply from 192.168.1.209: bytes=56 Sequence=1 ttl=255 time=50 ms
    Reply from 192.168.1.209: bytes=56 Sequence=2 ttl=255 time=50 ms

[Huawei]ping -a 192.168.1.193 192.168.1.130
  PING 192.168.1.130: 56  data bytes, press CTRL_C to break
    Reply from 192.168.1.130: bytes=56 Sequence=1 ttl=253 time=50 ms
    Reply from 192.168.1.130: bytes=56 Sequence=2 ttl=253 time=40 ms
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值