构建直连三层组网直接转发WLAN
本案例將說明采用AC+FIT架構(gòu)、直連三層組網(wǎng)和直接轉(zhuǎn)發(fā)方式下構(gòu)建WLAN的基本配置過程。網(wǎng)絡(luò)拓撲如圖3-1-15所示。案例中使用了VLAN pool作為業(yè)務(wù)VLAN。
圖3-1-15直連三層組網(wǎng)直接轉(zhuǎn)發(fā)
1. 參數(shù)規(guī)劃
三層組網(wǎng)時,AP和AC不在同一個網(wǎng)段,因此管理VLAN有兩個,一個VLAN用于AP管理,另一個VLAN是AC所在的VLAN。
| 表3-1-10參數(shù)規(guī)劃表 | |
| 項目 | 數(shù)據(jù) |
| 管理VLAN(AP) | VLAN10 |
| 管理VLAN(AC) | VLAN100 |
| STA業(yè)務(wù)VLAN | VLAN pool
|
| AC與Router互通 | VLAN200: AC創(chuàng)建VLANIF200并配置IP地址10.1.200.2/24;Router接口G0/0/0配置IP地址10.1.200.1/24 |
| DHCP服務(wù)器 | AC作為AP、STA的DHCP服務(wù)器 |
| AP地址池 | 10.1.10.2~10.1.10.254/24 |
| STA地址池 | 10.1.101.2~10.1.101.254/24 10.1.102.2~10.1.102.254/24 |
| AC源接口IP地址 | VLANIF100:10.1.100.1/24 |
| AP組 |
|
| 域管理模板 |
|
| SSID模板 |
|
| VAP模板 |
|
2. 配置步驟
1)配置網(wǎng)絡(luò)互通
# 配置接入交換機SW1的GE0/0/1、GE0/0/2接口加入VLAN10、VLAN101和VLAN102,GE0/0/1的缺省VLAN為VLAN10。直接轉(zhuǎn)發(fā)模式下,無線業(yè)務(wù)數(shù)據(jù)幀不再通過CAPWAP隧道轉(zhuǎn)發(fā),而是按照有線數(shù)據(jù)幀相同的方式轉(zhuǎn)發(fā),因此,相應(yīng)的設(shè)備端口需要放行業(yè)務(wù)VLAN。
<HUAWEI>system-view
[HUAWEI] sysname SW1
[SW1] vlan batch 10 101 102
[SW1] interface gigabitethernet 0/0/1
[SW1-GigabitEthernet0/0/1] port link-type trunk
[SW1-GigabitEthernet0/0/1] port trunk pvid vlan 10
[SW1-GigabitEthernet0/0/1] port trunk allow-pass vlan 10 101 102
[SW1-GigabitEthernet0/0/1] port-isolate enable
[SW1-GigabitEthernet0/0/1] quit
[SW1] interface gigabitethernet 0/0/2
[SW1-GigabitEthernet0/0/2] port link-type trunk
[SW1-GigabitEthernet0/0/2] port trunk allow-pass vlan 10 101 102
[SW1-GigabitEthernet0/0/2] quit
# 配置匯聚交換機SW2的接口GE0/0/1加入VLAN10、VLAN101和VLAN102,接口GE0/0/2加入VLAN100、VLAN101和VLAN102,并創(chuàng)建接口VLANIF100,地址為10.1.100.2/24。
<HUAWEI>system-view
[HUAWEI] sysname SW2
[SW2] vlan batch 10 100 101 102
[SW2] interface gigabitethernet 0/0/1
[SW2-GigabitEthernet0/0/1] port link-type trunk
[SW2-GigabitEthernet0/0/1] port trunk allow-pass vlan 10 101 102
[SW2-GigabitEthernet0/0/1] quit
[SW2] interface gigabitethernet 0/0/2
[SW2-GigabitEthernet0/0/2] port link-type trunk
[SW2-GigabitEthernet0/0/2] port trunk allow-pass vlan 100 101 102
[SW2-GigabitEthernet0/0/2] quit
[SW2] interface vlanif 100
[SW2-Vlanif100] ip address 10.1.100.2 24
[SW2-Vlanif100] quit
# Router的接口GE0/0/0配置IP地址10.1.200.1/24。
<Huawei>system-view
[Huawei] sysname Router
[Router] interface gigabitethernet 0/0/0
[Router-GigabitEthernet0/0/0] ip add 10.1.200.1 24
# 在Router上配置目的地址為用戶網(wǎng)段的靜態(tài)路由。
[Router]ip route-static 10.1.101.0 24 10.1.200.2
[Router]ip route-static 10.1.102.0 24 10.1.200.2
# 配置AC的接口GE0/0/1加入VLAN100、VLAN101和VLAN102,GE0/0/2加入VLAN200,并創(chuàng)建接口VLANIF100、VLANIF200。直接轉(zhuǎn)發(fā)模式下,相應(yīng)的設(shè)備端口需要放行業(yè)務(wù)VLAN,所以,AC的接口GE0/0/1放行了VLAN101和VLAN102。
<AC6605>system-view
[AC6605] sysname AC
[AC] vlan batch 100 101 102 200
[AC] interface vlanif 100
[AC-Vlanif100] ip address 10.1.100.1 24
[AC-Vlanif100] quit
[AC] interface vlanif 200
[AC-Vlanif100] ip address 10.1.200.2 24
[AC-Vlanif100] quit
[AC] interface gigabitethernet 0/0/1
[AC-GigabitEthernet0/0/1] port link-type trunk
[AC-GigabitEthernet0/0/1] port trunk allow-pass vlan 100 101 102
[AC-GigabitEthernet0/0/1] quit
[AC] interface gigabitethernet 0/0/2
[AC-GigabitEthernet0/0/2] port link-type access
[AC-GigabitEthernet0/0/2] port default vlan 200
[AC-GigabitEthernet0/0/2] quit
# 配置AC到AP的路由,下一跳為SW2的VLANIF100。AP與AC之間必須路由可達。
[AC] ip route-static 10.1.10.0 24 10.1.100.2
2)配置DHCP服務(wù)器為STA和AP分配IP地址
# 在SW2上為AP配置DHCP中繼。
[SW2] dhcp enable
[SW2] interface vlanif 10
[SW2-Vlanif10] ip address 10.1.10.1 24
[SW2-Vlanif10] dhcp select relay
[SW2-Vlanif10] dhcp relay server-ip 10.1.100.1
[SW2-Vlanif10] quit
# 在AC上創(chuàng)建VLANIF101和VLANIF102接口為STA提供地址。
[AC] dhcp enable
[AC] interface vlanif 101
[AC-Vlanif101] ip address 10.1.101.1 24
[AC-Vlanif101] dhcp select interface
[AC-Vlanif101] quit
[AC] interface vlanif 102
[AC-Vlanif102] ip address 10.1.102.1 24
[AC-Vlanif102] dhcp select interface
[AC-Vlanif102] quit
# 在AC上創(chuàng)建全局地址池為AP提供地址。在全局地址池中,通過選項option 43提供AC的IP地址。
[AC] ip pool wlan-ap
[AC-ip-pool-wlan-ap] network 10.1.10.0 mask 24
[AC-ip-pool-wlan-ap] gateway-list 10.1.10.1
[AC-ip-pool-wlan-ap] option 43 sub-option 3 ascii 10.1.100.1
[AC-ip-pool-wlan-ap] quit
# 配置VLAN pool,用于作為業(yè)務(wù)VLAN。在AC上新建VLAN pool,并將VLAN101和VLAN102加入其中,配置VLAN pool中的VLAN分配算法為“hash”。本例VLAN pool中的VLAN分配算法配置為“hash”。分配算法缺省情況下為“hash”,如果之前沒有修改其缺省配置,可以不用執(zhí)行命令assignment hash。
[AC] vlan batch 101 102
[AC] vlan pool sta-pool
[AC-vlan-pool-sta-pool] vlan 101 102
[AC-vlan-pool-sta-pool] assignment hash
[AC-vlan-pool-sta-pool] quit
3)配置AP上線
# 創(chuàng)建AP組,用于將相同配置的AP都加入同一AP組中。
[AC] wlan
[AC-wlan-view] ap-group name ap-group1
[AC-wlan-ap-group-ap-group1] quit
# 創(chuàng)建域管理模板,在域管理模板下配置AC的國家碼并在AP組下引用域管理模板。
[AC-wlan-view] regulatory-domain-profile name default
[AC-wlan-regulate-domain-default] country-code cn
[AC-wlan-regulate-domain-default] quit
[AC-wlan-view] ap-group name ap-group1
[AC-wlan-ap-group-ap-group1] regulatory-domain-profile default
Warning: Modifying the country code will clear channel, power and antenna gain configurations of the radio and reset the AP. Continu
e?[Y/N]:y
[AC-wlan-ap-group-ap-group1] quit
[AC-wlan-view] quit
# 配置AC的源接口。
[AC]capwap source ip-address 10.1.100.1
# 在AC上離線導(dǎo)入AP,并將AP加入AP組“ap-group1”中。假設(shè)AP的MAC地址為60ae-5268-c250,并且根據(jù)AP的部署位置為AP配置名稱,便于從名稱上就能夠了解AP的部署位置。例如MAC地址為60ae-5268-c250(所對應(yīng)的AP 的MAC地址)的AP部署在辦公區(qū)域,命名此AP為office。
[AC] wlan
[AC-wlan-view] ap auth-mode mac-auth
[AC-wlan-view] ap-id 0 ap-mac 60ae-5268-c250(所對應(yīng)的AP 的MAC地址)
[AC-wlan-ap-0] ap-name office
Warning: This operation may cause AP reset. Continue? [Y/N]:y
[AC-wlan-ap-0] ap-group ap-group1
Warning: This operation may cause AP reset. If the country code changes, it will clear channel, power and antenna gain configuration
s of the radio, Whether to continue? [Y/N]:y
[AC-wlan-ap-0] quit
# 將AP上電后,當(dāng)執(zhí)行命令display ap all查看到AP的“State”字段為“nor”時,表示AP正常上線。
?
4)配置WLAN業(yè)務(wù)參數(shù)
# 創(chuàng)建名為“WLAN-SZ”的SSID模板,并配置SSID名稱為“WLAN-SZ”。
[AC-wlan-view] ssid-profile name WLAN-SZ
[AC-wlan-ssid-prof-WLAN-SZ] ssid WLAN-SZ
[AC-wlan-ssid-prof-WLAN-SZ] quit
# 創(chuàng)建名為“wlan-sz”的VAP模板,配置業(yè)務(wù)數(shù)據(jù)轉(zhuǎn)發(fā)模式為直接轉(zhuǎn)發(fā)(direct-forward)、業(yè)務(wù)VLAN,并且引用SSID模板。
[AC-wlan-view] vap-profile name wlan-sz
[AC-wlan-vap-prof-wlan-sz] forward-mode direct-forward
[AC-wlan-vap-prof-wlan-sz] service-vlan vlan-pool sta-pool
[AC-wlan-vap-prof-wlan-sz] ssid-profile wlan-sz
[AC-wlan-vap-prof-wlan-sz] quit
# 配置AP組引用VAP模板,AP上射頻0和射頻1都使用VAP模板“wlan-sz”的配置。
[AC-wlan-view] ap-group name ap-group1
[AC-wlan-ap-group-ap-group1] vap-profile wlan-sz wlan 1 radio 0
[AC-wlan-ap-group-ap-group1] vap-profile wlan-sz wlan 1 radio 1
[AC-wlan-ap-group-ap-group1] quit
5)配置AP射頻的信道和功率
#關(guān)閉射頻的信道和功率自動調(diào)優(yōu)功能。
[AC-wlan-view] rrm-profile name default
[AC-wlan-rrm-prof-default] calibrate auto-channel-select disable
[AC-wlan-rrm-prof-default] calibrate auto-txpower-select disable
[AC-wlan-rrm-prof-default] quit
# 配置AP射頻0的信道和功率。
[AC-wlan-view] ap-id 0
[AC-wlan-ap-0] radio 0
[AC-wlan-radio-0/0] channel 20mhz 6
Warning: This action may cause service interruption. Continue?[Y/N]y
[AC-wlan-radio-0/0] eirp 127
[AC-wlan-radio-0/0] quit
# 配置AP射頻1的信道和功率。
[AC-wlan-ap-0] radio 1
[AC-wlan-radio-0/1] channel 20mhz 149
Warning: This action may cause service interruption. Continue?[Y/N]y
[AC-wlan-radio-0/1] eirp 127
[AC-wlan-radio-0/1] quit
[AC-wlan-ap-0] quit
6)驗證配置結(jié)果
WLAN業(yè)務(wù)配置會自動下發(fā)給AP,配置完成后,通過執(zhí)行命令display vap ssid wlan-sz查看如下信息,當(dāng)“Status”項顯示為“ON”時,表示AP對應(yīng)的射頻上的VAP已創(chuàng)建成功。
STA搜索到名為“wlan-sz”的無線網(wǎng)絡(luò),并正常關(guān)聯(lián)后,在AC上執(zhí)行display station ssid wlan-sz命令,可以查看到用戶已經(jīng)接入到無線網(wǎng)絡(luò)“wlan-sz”中。
?
測試連通性:STA ping Router,觀察結(jié)果。
?
?
總結(jié)
以上是生活随笔為你收集整理的构建直连三层组网直接转发WLAN的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Java学习路线从入门到入土
- 下一篇: Nutanix 发布全新的 “精英联盟合