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 

相关推荐

最近更新

  1. docker php8.1+nginx base 镜像 dockerfile 配置

    2024-01-30 08:34:01       98 阅读
  2. Could not load dynamic library ‘cudart64_100.dll‘

    2024-01-30 08:34:01       106 阅读
  3. 在Django里面运行非项目文件

    2024-01-30 08:34:01       87 阅读
  4. Python语言-面向对象

    2024-01-30 08:34:01       96 阅读

热门阅读

  1. 【PostGIS】POSTGIS实现聚类统计提取外轮廓

    2024-01-30 08:34:01       67 阅读
  2. 后端商品分类显示接口实现

    2024-01-30 08:34:01       39 阅读
  3. arch liunx安装android studio

    2024-01-30 08:34:01       52 阅读
  4. uniapp日志写入

    2024-01-30 08:34:01       57 阅读
  5. WebSocket详解

    2024-01-30 08:34:01       45 阅读
  6. 实时搜索建议

    2024-01-30 08:34:01       54 阅读
  7. log4j 日志级别及优先级排序

    2024-01-30 08:34:01       65 阅读