要求:
1,R6为ISP,只能配置IP地址,R1-R5的环回为私有网段
2,R1/4/5为全连的MGRE结构,R1/2/3为星型的拓扑结构,R1为中心站点
3,所有私有网段可以互相通讯,私有网段使用OSPF完成
要求一
以R1为例
[r1]interface g0/0/0
[r1-GigabitEthernet0/0/0]ip address 61.0.0.2 24
Apr 5 2024 18:19:06-08:00 r1 %%01IFNET/4/LINK_STATE(l)[0]:The line protocol IP on the interfaceGigabitEthernet0/0/0 has entered the UP state.
[r1]interface g0/0/1
[r1-GigabitEthernet0/0/1]ip address 16.0.0.2 24
Apr 5 2024 18:19:18-08:00 r1 %%01IFNET/4/LINK_STATE(l)[1]:The line protocol IP on the interfaceGigabitEthernet0/0/1 has entered the UP state.
[r1]interface l0
[r1-LoopBack0]ip address 1.1.1.1 24
填写缺省路由
[r1]ip route-static 0.0.0.0 0 16.0.0.1
[r1]ip route-static 0.0.0.0 0 61.0.0.1
要求二
以R1为中心站点进行配置
[r4]interface t0/0/0
[r4-Tunnel0/0/0]ip address 192.168.1.2 24
[r4-Tunnel0/0/0]tunnel-protocol gre p2mp
[r4-Tunnel0/0/0]source g0/0/0
Apr 10 2024 11:20:06-08:00 r4 %%01IFNET/4/LINK_STATE(l)[0]:The line protocol IP
on the interface Tunnel0/0/0 has entered the UP state.
[r4-Tunnel0/0/0]nhrp entry 192.168.1.1 16.0.0.2 register
R5同理
最后在三台设备上修改网络接口类型为broadcast,实现全连
要求三
OSPF宣告
ospf 1 router-id 1.1.1.1
area 0.0.0.0
network 1.1.1.1 0.0.0.0
network 192.168.1.0 0.0.0.255
network 192.168.2.0 0.0.0.255
测试全网可达