☰
总部和分支建立GRE+分支通过总部统一出口去互联网组网
2026/9/27 22:48:37 网站建设 项目流程

一 组网说明

 

如上图:

总部和分支组网,由于分支未申请互联网出口,只能总部和分支建立GRE隧道,分支和总部都通过总部的一个出口访问互联网。

总结方法:

方法1:分支配置明细路由到达总部出口公网地址,建立GRE隧道,然后配置默认路由扔向GRE隧道接口;这样去往总部内网和互联网都通过GRE隧道扔向总部,去往互联网的路由在通过总部出口出去;

方法2:分支配置默认路由到达总部出口公网地址,建立GRE隧道,然后配置总部内网明细路由扔向GRE隧道接口,配置去往公网的明细路由扔向GRE隧道接口;这样去往内网明细和部分公网的路由通过GRE隧道扔向总部,去往互联网的路由在通过总部出口出去。缺点是公网地址太多都需要写明细路由扔向总部,会比较麻烦。

注意:这也是很多SDWAN统一互联网出口或者集中总部上网的实现方式。

二 设备配置

2.1 ZB设备配置

sysname ZB

#

ip unreachables enable

ip ttl-expires enable

#

lldp global enable

#

acl advanced 3000

description NAT

rule 0 permit ip

#

interface GigabitEthernet0/0

port link-mode route

combo enable copper

ip address 202.1.1.1 255.255.255.0

nat outbound 3000

#

interface GigabitEthernet0/1

port link-mode route

combo enable copper

ip address 192.168.1.1 255.255.255.0

#

interface Tunnel1 mode gre

ip address 1.1.1.1 255.255.255.252

source 202.1.1.1

destination 203.1.1.1

#

ip route-static 0.0.0.0 0 202.1.1.2

ip route-static 192.168.2.0 24 Tunnel1

#

2.2 FZ设备配置

sysname FZ

#

ip unreachables enable

ip ttl-expires enable

#

lldp global enable

#

acl advanced 3000

description NAT

rule 0 permit ip

#

interface GigabitEthernet0/0

port link-mode route

combo enable copper

ip address 203.1.1.1 255.255.255.0

nat outbound 3000

#

interface GigabitEthernet0/1

port link-mode route

combo enable copper

ip address 192.168.2.1 255.255.255.0

#

interface Tunnel1 mode gre

ip address 1.1.1.2 255.255.255.252

source 203.1.1.1

destination 202.1.1.1

#

ip route-static 0.0.0.0 0 Tunnel1

ip route-static 202.1.1.0 24 203.1.1.2

#

2.3 ISP设备配置

sysname ISP

#

ip unreachables enable

ip ttl-expires enable

#

需要专业的网站建设服务?

联系我们获取免费的网站建设咨询和方案报价,让我们帮助您实现业务目标

立即咨询