DM spoke-to-spoke

本文档详细介绍了网络基础设施的配置,包括交换机的VLAN设置、路由器的静态路由与DHCP配置,以及mGRE隧道和NHRP的建立。在隧道配置部分,展示了R1、R2和R3之间的点到多点连接,并通过测试验证了无需中转的直接通信。此外,还涵盖了EIGRP和OSPF路由协议在隧道环境中的应用,以及加密策略的实现,确保了网络通信的安全性。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

目录

底层

建隧道

测试

R1

 R2

接入设备(lo 0)

eigrp

OSPF

       Broadcast

 PTMP点到多点

加密


 

底层

switch
 
vlan 100,128,172
exit
 
int vlan 100
ip add 202.100.1.0 255.255.255.0
 
int vlan 128
ip add 61.128.1.100 255.255.255.0
 
int vlan 172
ip add 255.255.255.0
 
int g0/0
sw mo ac
sw ac vlan 100
 
int g0/1
sw mo ac
sw ac vlan 128
 
int g0/2
sw mo ac
sw ac vlan 172

ip dh poo v202
netw 202.100.1.0 /24
 
ip dh poo v128
netw 61.128.1.0 /24
 
ip dh poo v172
netw 172.9.1.0 /24
R1
 
int g0/0
ip add dhcp
int lo 0
ip add 10.1.1.1 255.255.255.0
 
ip route 0.0.0.0 0.0.0.0 200.100.1.100
R2
 
int g0/0
ip add dhcp
 
int lo 0
ip add 10.1.2.1 255.255.255.0
 
ip route 0.0.0.0 0.0.0.0 61.128.1.100
    R3
     
    int g0/0
    ip add dhcp
    int lo 0
    ip add 10.1.3.1 255.255.255.0
     
    ip route 0.0.0.0 0.0.0.0 172.9.1.100

建隧道

mGRE和NHRP配置

R1

int t0
ip add 10.1.123.1 255.255.255.0
tun sou g0/0
tun mode gre multipoint
ip nhrp netw 123
R2

int t0
ip add 10.1.123.2 255.255.255.0
ip nhrp netw 123
tun so g0/0
tun mo gre mu 

ip nhrp nhs 10.1.123.1 nbma 202.100.1.1 //高版本

低版本
ip nhrp map 10.1.123.1 202.100.1.1
ip nhrp nhs 10.1.123.1
R3

int t0
ip add 10.1.123.3 255.255.255.0
ip nhrp netw 123
tun so g0/0
tun mo gre mu 
ip nhrp nhs 10.1.123.1 nbma 202.100.1.1 

测试

R1

 

 R2

 

 通过pingR3,在R1上学到去往R3的映射表项,之后R2可直接去往R3,不需要HUB中转

 

接入设备(lo 0)

eigrp

R1

int t0
ip nhrp map multicast dynamic
no ip split-horizon eigrp 90  关闭水平分割
no ip next-hop-self eigrp 90  关闭第三方下一跳

router eigrp 90
no au
netw 10.1.1.0 0.0.0.255
netw 10.1.123.0 0.0.0.255
R2

int t0
ip nhrp map multicast 202.100.1.1


router eigrp 90
no au
netw 10.1.2.0 0.0.0.255
netw 10.1.123.0 0.0.0.255
R3

int t0
ip nhrp map multicast 202.100.1.1


router eigrp 90
no au
netw 10.1.3.0 0.0.0.255
netw 10.1.123.0 0.0.0.255

tunnnel 0 接口 sh no sh  翻动一下

 

 

 R1 t0上关闭了eigrp的第三方下一跳,R2,R3上去往对端的ip下一跳是从R1的映射上学习的

OSPF

       Broadcast

R1

int t0
ip nhrp map mu dy
ip os netw broadcast     //gre tunnel默认PTP,需要修改

router os 1
router-id 1.1.1.1
netw 10.1.1.0 0.0.0.255 a 0
netw 10.1.123.0 0.0.0.255 a 0
R2

int t0
ip nhrp map mu dy
ip os netw br
ip os prio 0    修改端口优先级,确保R1是DR

router os 1
router-id 2.2.2.2
netw 10.1.2.0 0.0.0.255 a 0
netw 10.1.123.0 0.0.0.255 a 0
R3

int t0
ip nhrp map mu dy
ip os netw br
ip os prio 0

router os 1
router-id 3.3.3.3
netw 10.1.3.0 0.0.0.255 a 0
netw 10.1.123.0 0.0.0.255 a 0

 PTMP点到多点
 

R1

int t0
ip nhrp map mu dy
ip os netw point-to-mu
ip nhrp redirect
R2,R3

int t0
ip nhrp map mu 202.100.1.1
ip os netw p    mu
ip nhrp shortcut  路径优化

 

 

加密

R1
crypto isa po 10
au pre
en 3des
group 2
ha sh
exit
 
crypto isa key cisco add 0.0.0.0
 
crypto ipsec tr TS esp-3 esp-sha-hmac
mod tun
 
crypto ipsec pr PRF
set tr TS
exit
 
int t0
tun proection ipsec PRF
R2
crypto isa po 10
au pre
en 3des
group 2
ha sh
exit
 
crypto isa key cisco add 202.100.1.1
crypto isa key cisco add 172.9.0.0 255.255.255.0.0
 
crypto ipsec tr TS esp-3 esp-sha-h
mod tun
 
crypto ipsec pr PRF
set tr TS
exit
 
int t0
tun proection ipsec PRF
R3
crypto isa po 10
au pre
en 3des
group 2
ha sh
exit
 
crypto isa key cisco add 202.100.1.1
crypto isa key cisco add 61.128.0.0 255.255.255.0.0
 
crypto ipsec tr TS esp-3 esp-sha-h
mod tun
 
crypto ipsec pr PRF
set tr TS
exit
 
int t0
tun proection ipsec PRF

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值