OSPF下的MGRE实验AAA

一丶实验要求

1. R1-R3-R4构建全连的MGRE环境
2. R1-R5-R6建立hub-spoke的MGRE环境,其中R1为中心
3. R1-R3...R6均存在环回网段模拟用户私网,使用OSPF使全网可达
4. 其中R2为ISP路由器,仅配置IP地址

二丶IP规划

如下图

三丶底层IP配置

以r1 g0/0/0接口为例,配置各个路由接口

[r1]inter    
[r1]interface g0/0/0
[r1-GigabitEthernet0/0/0]ip rtou    
[r1-GigabitEthernet0/0/0]ip add    
[r1-GigabitEthernet0/0/0]ip address 12.0.0.1 24

ISP

interface GigabitEthernet0/0/0
 ip address 12.0.0.2 255.255.255.0 
#
interface GigabitEthernet0/0/1
 ip address 21.0.0.2 255.255.255.0 
#
interface GigabitEthernet0/0/2
 ip address 23.0.0.2 255.255.255.0 
#
interface GigabitEthernet4/0/0
 ip address 24.0.0.2 255.255.255.0 
#
interface GigabitEthernet4/0/1
 ip address 25.0.0.2 255.255.255.0 
#
interface GigabitEthernet4/0/2
 ip address 26.0.0.2 255.255.255.0 

四丶R1-R3-R4构建全连的MGRE环境

R1

interface Tunnel0/0/0
 ip address 192.168.2.1 255.255.255.0 
 tunnel-protocol gre p2mp
 source GigabitEthernet0/0/1
 ospf network-type broadcast
 nhrp entry multicast dynamic
 nhrp network-id 100
 nhrp entry 192.168.2.3 23.0.0.1 register

R3

interface Tunnel0/0/0
 ip address 192.168.2.3 255.255.255.0 
 tunnel-protocol gre p2mp
 source GigabitEthernet0/0/0
 ospf network-type broadcast
 nhrp entry multicast dynamic
 nhrp network-id 100
 nhrp entry 192.168.2.4 24.0.0.1 register

R4

interface Tunnel0/0/0
 ip address 192.168.2.4 255.255.255.0 
 tunnel-protocol gre p2mp
 source GigabitEthernet0/0/0
 ospf network-type broadcast
 nhrp entry multicast dynamic
 nhrp network-id 100
 nhrp entry 192.168.2.1 21.0.0.1 register


五丶R1-R5-R6建立hub-spoke的MGRE环境,其中R1为中心

R1

interface Tunnel0/0/1
 ip address 192.168.7.1 255.255.255.0 
 tunnel-protocol gre p2mp
 source GigabitEthernet0/0/0
 ospf network-type p2mp
 nhrp entry multicast dynamic
 nhrp network-id 100

R5

interface Tunnel0/0/0
 ip address 192.168.7.2 255.255.255.0 
 tunnel-protocol gre p2mp
 source GigabitEthernet0/0/0
 ospf network-type p2mp
 nhrp entry 192.168.7.1 12.0.0.1 register

R6

interface Tunnel0/0/0
 ip address 192.168.7.3 255.255.255.0 
 tunnel-protocol gre p2mp
 source GigabitEthernet0/0/0
 ospf network-type p2mp
 nhrp entry 192.168.7.1 12.0.0.1 register

六丶R1-R3...R6均存在环回网段模拟用户私网,使用OSPF使全网可达

R1

ip route-static 0.0.0.0 0.0.0.0 12.0.0.2
ip route-static 0.0.0.0 0.0.0.0 21.0.0.2

ospf 1 router-id 1.1.1.1 
 area 0.0.0.0 
  network 192.168.1.0 0.0.0.255 
  network 192.168.2.0 0.0.0.255 
  network 192.168.7.0 0.0.0.255

R3

ip route-static 0.0.0.0 0.0.0.0 23.0.0.2

ospf 1 router-id 3.3.3.3 
 area 0.0.0.0 
  network 192.168.2.0 0.0.0.255 
  network 192.168.3.0 0.0.0.255 

R4

ip route-static 0.0.0.0 0.0.0.0 24.0.0.2

ospf 1 router-id 4.4.4.4 
 area 0.0.0.0 
  network 192.168.2.0 0.0.0.255 
  network 192.168.4.0 0.0.0.255 

R5

ip route-static 0.0.0.0 0.0.0.0 25.0.0.2

ospf 1 router-id 5.5.5.5 
 area 0
  network 192.168.5.0 0.0.0.255 
  network 192.168.7.0 0.0.0.255 

R6

ip route-static 0.0.0.0 0.0.0.0 26.0.0.2

ospf 1 router-id 6.6.6.6 
 area 0
  network 192.168.6.0 0.0.0.255 
  network 192.168.7.0 0.0.0.255 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

胖虎不是胖虎

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值