news 2026/5/1 7:51:43

WLAN二层旁挂组网-隧道转发

作者头像

张小明

前端开发工程师

1.2k 24
文章封面图
WLAN二层旁挂组网-隧道转发

WLAN二层隧道转发是一种数据转发模式,AP和AC之间通过CAPWAP隧道封装用户数据,所有用户报文都先送到AC集中处理,再由AC转发出去。

核心特点

  • 集中控制‌:所有用户数据都经过AC处理,便于统一管理和安全控制。
  • 配置简单‌:通常只需要在AP和AC直连的接口上配置为Trunk模式,允许业务VLAN通过。
  • 适用场景‌:适合中小规模网络,或者对集中管理和安全要求较高的环境。

​​​​​​​

R1路由配置

[Huawei-GigabitEthernet0/0/1]interface GigabitEthernet 0/0/0

[Huawei-GigabitEthernet0/0/0]ip add 192.168.111.1 24

[Huawei-GigabitEthernet0/0/0]quit

[Huawei]ip route-static 192.168.0.0 16 192.168.111.2

SW1核心交换机配置

<Huawei>system-view

[Huawei]vlan batch 100 111 110

[Huawei]interface vlanif100

[Huawei-Vlanif100]ip add 192.168.100.1 24

[Huawei-Vlanif100]interface vlanif111

[Huawei-Vlanif111]ip add 192.168.111.2 24

[Huawei]interface vlanif110

[Huawei-Vlanif110]ip add 192.168.110.1 24

[Huawei-Vlanif110]quit

[Huawei]interface GigabitEthernet 0/0/1

[Huawei-GigabitEthernet0/0/1]port link-type access

[Huawei-GigabitEthernet0/0/1]port default vlan 111

[Huawei-GigabitEthernet0/0/1]interface GigabitEthernet 0/0/2

[Huawei-GigabitEthernet0/0/2]port link-type trunk

[Huawei-GigabitEthernet0/0/2]port trunk allow-pass vlan 100 110

[Huawei-GigabitEthernet0/0/2]port trunk pvid vlan 100

[Huawei-GigabitEthernet0/0/2]interface GigabitEthernet 0/0/3

[Huawei-GigabitEthernet0/0/3]port link-type access

[Huawei-GigabitEthernet0/0/3]port default vlan 100

[Huawei-GigabitEthernet0/0/3]quit

[Huawei]ip route-static 0.0.0.0 0 192.168.111.1

[Huawei]ip route-static 192.168.0.0 16 192.168.110.2

AC1上面的配置

<AC6605>system-view

[AC6605]vlan batch 100 110

[AC6605]interface vlanif 110

[AC6605-Vlanif110]ip add 192.168.110.2 24

[AC6605-Vlanif110]interface vlanif 100

[AC6605-Vlanif100]ip add 192.168.100.2 24

[AC6605]interface GigabitEthernet 0/0/1

[AC6605-GigabitEthernet0/0/1]port link-type trunk

[AC6605-GigabitEthernet0/0/1]port trunk pvid vlan 100

[AC6605-GigabitEthernet0/0/1]port trunk allow-pass 100 110

[AC6605-GigabitEthernet0/0/1]quit

[AC6605]vlan batch 101 102

[AC6605]interface vlanif 101

[AC6605-Vlanif101]ip add 192.168.101.1 24

[AC6605-Vlanif101]interface vlanif 102

[AC6605-Vlanif102]ip add 192.168.102.1 24

[AC6605-Vlanif102]quit

[AC6605]ip route-static 0.0.0.0 0 192.168.110.1

AC1上配置DHCP

[AC6605]dhcp enable

[AC6605]ip pool vlan100

[AC6605-ip-pool-vlan100]network 192.168.100.0 mask 24

[AC6605-ip-pool-vlan100]gateway-list 192.168.100.1

[AC6605-ip-pool-vlan100]dns-list 8.8.8.8

[AC6605-ip-pool-vlan100]quit

[AC6605]ip pool vlan101

[AC6605-ip-pool-vlan101]network 192.168.101.0 mask 24

[AC6605-ip-pool-vlan101]gateway-list 192.168.101.1

[AC6605-ip-pool-vlan101]dns-list 8.8.8.8

[AC6605-ip-pool-vlan101]quit

[AC6605]ip pool vlan102

[AC6605-ip-pool-vlan102]network 192.168.102.0 mask 24

[AC6605-ip-pool-vlan102]gateway-list 192.168.102.1

[AC6605-ip-pool-vlan102]dns-list 8.8.8.8

[AC6605-ip-pool-vlan102]quit

[AC6605]interface vlanif 100

[AC6605-Vlanif100]dhcp select global

[AC6605-Vlanif100]quit

[AC6605]interface vlanif101

[AC6605-Vlanif101]dhcp select global

[AC6605-Vlanif101]quit

[AC6605]interface vlanif102

[AC6605-Vlanif102]dhcp select global

[AC6605-Vlanif102]quit

在AC1上配置AP上线

指定和AP建立capwap的地址或接口

[AC6605]capwap source interface vlanif 100

配置域管理模版

[AC6605]wlan

[AC6605-wlan-view]regulatory-domain-profile name default

[AC6605-wlan-regulate-domain-default]country-code cn

[AC6605-wlan-regulate-domain-default]quit

创建AP组(因为有多个AP所以创建组来进行区分)

[AC6605]wlan

[AC6605-wlan-view]ap-group name ap-office1

[AC6605-wlan-ap-group-ap-office1]regulatory-domain-profile default

onfigurations of the radio and reset the AP. Continue?[Y/N]:y

[AC6605-wlan-ap-group-ap-office1]quit

[AC6605-wlan-view]ap-group name ap-office2

[AC6605-wlan-ap-group-ap-office2]regulatory-domain-profile default

onfigurations of the radio and reset the AP. Continue?[Y/N]:y

[AC6605-wlan-ap-group-ap-office2]quit

[AC6605-wlan-view]

将AP添加到AP组中

[AC6605-wlan-view]ap-id 1 ap-mac 00e0-fc6e-26b0

[AC6605-wlan-ap-1]ap-name ap1

[AC6605-wlan-ap-1]ap-group ap-office1

Warning: This operation may cause AP reset. If the country code changes, it willclear channel, power and antenna gain configurations of the radio, Whether to continue? [Y/N]:y

Info: This operation may take a few seconds. Please wait for a moment.. done.

[AC6605-wlan-ap-1]quit

[AC6605-wlan-view]ap-id 2 ap-mac 00e0-fcc0-34c0

[AC6605-wlan-ap-2]ap-name ap2

[AC6605-wlan-ap-2]ap-group ap-office1

Warning: This operation may cause AP reset. If the country code changes, it will clear channel, power and antenna gain configurations of the radio, Whether to continue? [Y/N]:y

Info: This operation may take a few seconds. Please wait for a moment.. done.

[AC6605-wlan-ap-2]quit

[AC6605-wlan-view]ap-id3ap-mac00e0-fca7-18d0

[AC6605-wlan-ap-3]ap-name ap3

[AC6605-wlan-ap-3]ap-group ap-office2

Warning: This operation may cause AP reset. If the country code changes, it willclear channel, power and antenna gain configurations of the radio, Whether to continue? [Y/N]:y

Info: This operation may take a few seconds. Please wait for a moment.. done.

[AC6605-wlan-ap-3]quit

[AC6605-wlan-view]ap-id4ap-mac00e0-fc8f-3db0

[AC6605-wlan-ap-4]ap-name ap4

[AC6605-wlan-ap-4]ap-group ap-office2

Warning: This operation may cause AP reset. If the country code changes, it will clear channel, power and antenna gain configurations of the radio, Whether to continue? [Y/N]:y

Info: This operation may take a few seconds. Please wait for a moment.. done.

[AC6605-wlan-ap-4]quit

配置AP上线

  1. 配置SSID模版
  2. 配置安全模版
  3. 配置vap模版
  4. 在ap组中应用vap模版、

配置SSID模版

[AC6605]wlan

[AC6605-wlan-view]ssid-profile name ssid-office1

[AC6605-wlan-ssid-prof-ssid-office1]quit

[AC6605-wlan-view]ssid

[AC6605-wlan-view]ssid-profile name ssid-office2

[AC6605-wlan-ssid-prof-ssid-office2]

[AC6605-wlan-ssid-prof-ssid-office2]quit

配置安全模版

[AC6605-wlan-view]security-profile name sec-office1

[AC6605-wlan-sec-prof-sec-office1]security wpa-wpa2 psk pass-phrase a1234567 aes

[AC6605-wlan-sec-prof-sec-office1]security-profile name sec-office2

[AC6605-wlan-sec-prof-sec-office2]security wpa-wpa2 psk pass-phraseb1234567 aes

配置vap模版

[AC6605-wlan-view]vap-profile name vap-office1

[AC6605-wlan-vap-prof-vap-office1]forward-mode tunnel

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office1]service-vlan vlan-id 101

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office1]ssid-profile ssid-office1

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office1]security-profile sec-office1

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office1]quit

[AC6605-wlan-view]

[AC6605-wlan-view]vap-profile name vap-office2

[AC6605-wlan-vap-prof-vap-office2]forward-mode tunnel

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office2]service-vlan vlan-id 102

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office2]ssid-profile ssid-office2

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office2]security-profile sec-office2

Info: This operation may take a few seconds, please wait.done.

[AC6605-wlan-vap-prof-vap-office2]quit

在ap组中应用vap模版

[AC6605-wlan-view]ap-group name ap-office1

[AC6605-wlan-ap-group-ap-office1]vap-profile vap-office1 wlan 1 radio 0

Info: This operation may take a few seconds, please wait...done.

[AC6605-wlan-ap-group-ap-office1]vap-profile vap-office1 wlan 1 radio 1

Info: This operation may take a few seconds, please wait...done.

[AC6605-wlan-ap-group-ap-office1]quit

[AC6605-wlan-view]ap-group name ap-office2

[AC6605-wlan-ap-group-ap-office2]vap-profile vap-office2wlan2radio 0

Info: This operation may take a few seconds, please wait...done.

[AC6605-wlan-ap-group-ap-office2]vap-profile vap-office2wlan2radio 1

Info: This operation may take a few seconds, please wait...done.

[AC6605-wlan-ap-group-ap-office2]quit

测试结果

版权声明: 本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若内容造成侵权/违法违规/事实不符,请联系邮箱:809451989@qq.com进行投诉反馈,一经查实,立即删除!
网站建设 2026/4/29 19:03:43

5步打造全能游戏控制中心:虚拟手柄驱动实战指南

5步打造全能游戏控制中心&#xff1a;虚拟手柄驱动实战指南 【免费下载链接】ViGEmBus 项目地址: https://gitcode.com/gh_mirrors/vig/ViGEmBus 虚拟手柄驱动是解决游戏控制器兼容性问题的关键工具&#xff0c;能够实现跨平台游戏控制&#xff0c;让各类输入设备无缝协…

作者头像 李华
网站建设 2026/4/1 12:08:31

VibeVoice Pro效果可视化:300ms TTFB在WebRTC通话场景中的端到端体验实测

VibeVoice Pro效果可视化&#xff1a;300ms TTFB在WebRTC通话场景中的端到端体验实测 1. 为什么“300ms”不是参数&#xff0c;而是通话体验的分水岭 你有没有遇到过这样的情况&#xff1a;视频会议里刚开口说“你好”&#xff0c;对方却等了快一秒才听到第一个音节&#xff…

作者头像 李华
网站建设 2026/4/12 14:36:01

用GPEN镜像给祖辈老照片焕新,感动哭了

用GPEN镜像给祖辈老照片焕新&#xff0c;感动哭了 泛黄、模糊、布满划痕的老照片&#xff0c;藏着我们最珍贵的家族记忆。当爷爷奶奶年轻时的笑脸在斑驳影像中若隐若现&#xff0c;那种想触碰却无法清晰凝视的遗憾&#xff0c;许多人都经历过。直到今天&#xff0c;你不需要懂…

作者头像 李华
网站建设 2026/5/1 7:13:58

想做人脸超分辨率?试试这个开箱即用的GPEN镜像

想做人脸超分辨率&#xff1f;试试这个开箱即用的GPEN镜像 你有没有遇到过这样的情况&#xff1a;翻出一张十年前的老照片&#xff0c;人脸模糊得连五官都看不清&#xff1b;或者从监控截图里想还原嫌疑人面部细节&#xff0c;结果全是马赛克&#xff1b;又或者客户发来一张手…

作者头像 李华
网站建设 2026/4/27 14:32:33

想做电商主图?先试试这个AI抠图神器的真实效果

想做电商主图&#xff1f;先试试这个AI抠图神器的真实效果 你是不是也经历过这样的场景&#xff1a;刚拍完一批新品照片&#xff0c;兴冲冲打开PS准备换背景&#xff0c;结果花半小时才抠好人像边缘&#xff0c;发丝还毛毛躁躁&#xff1b;或者面对几十张商品图&#xff0c;一…

作者头像 李华
网站建设 2026/5/1 7:10:14

[特殊字符] Local Moondream2定制化:修改界面UI适配企业内部使用需求

&#x1f319; Local Moondream2定制化&#xff1a;修改界面UI适配企业内部使用需求 1. 为什么需要定制化&#xff1f;——从开箱即用到企业就绪 Local Moondream2本身是一个极简、高效的视觉对话工具&#xff0c;但它的默认界面设计面向的是个人开发者或技术爱好者&#xff…

作者头像 李华