配置Switch
[Switch]vlan batch 100 101
[Switch]interface Ethernet0/0/0/0/4
description Link-to-AP
port link-type trunk
port trunk pvid vlan 100
port trunk allow-pass vlan 100 101
quit
[Switch]interface Ethernet0/0/3
description Link-to-AC
port link-type trunk
port trunk allow-pass vlan 100 101
quit
rule 10 permit ip source 192.168.100.0 0.0.0.255
rule 20 permit ip source 192.168.101.0 0.0.0.255 destination 172.16.1.0 0.0.0.192
rule 500 deny ip
traffic-filter outbound acl 3000
traffic-filter inbound acl 3000
配置AC
[AC]vlan batch 100 101
[AC]interface GigabitEthernet0/0/1
[AC-GigabitEthernet0/0/1]description Link-to-SW
[AC-GigabitEthernet0/0/1]port link-type trunk
[AC-GigabitEthernet0/0/1]port trunk allow-pass vlan 100 101
[AC-GigabitEthernet0/0/1]quit
[AC]dhcp enable
[AC]interface vlanif 100
[AC -Vlanif100]description for-ap
[AC -Vlanif100]ip address 192.168.100.1 24
[AC -Vlanif100]dhcp select interface
[AC-Vlanif100]quit
[AC]interface vlanif 101
[AC -Vlanif101]ip address 192.168.101.1 24
[AC -Vlanif101]dhcp select interface
[A-Vlanif101]dhcp server dns-list 8.8.8.8
[ACVlanif101]quit
创建AP组,用于将相同配置的AP都加入同一AP组中
[AC6605]wlan
[AC6605-wlan-view]ap-group name ap-group1
[AC6605-wlan-ap-group-ap-group1]quit
创建域管理模板,在域管理模板下配置AC的国家码并在AP组下引用域管理模板。
[AC6605-wlan-view]regulatory-domain-profile name domain1
[AC6605-wlan-regulate-domain-domain1]country-code cn
[AC6605-wlan-regulate-domain-domain1]quit
[AC6605-wlan-view]ap-group name ap-group1
[AC6605-wlan-ap-group-ap-group1]regulatory-domain-profile domain1
[AC6605-wlan-ap-group-ap-group1]qui
[AC6605-wlan-ap-group-ap-group1]quit
[AC6605-wlan-view]quit
配置AC的源接口。
[AC6605]capwap source interface Vlanif 100
[AC6605]wlan
[AC6605-wlan-view]ap auth-mode mac-auth
[AC6605-wlan-view]ap-id 0 ap-mac 00e0-fca4-3660
[AC6605-wlan-ap-0]ap-name area_1
[AC6605-wlan-ap-0]ap-group ap-group1
[AC6605-wlan-ap-0] quit
配置WLAN业务参数
创建名为“wlan-security”的安全模板,并配置安全策略。
[AC6605]wlan
[AC6605-wlan-view]security-profile name wlan-security
[AC6605-wlan-sec-prof-wlan-security]security wpa2 psk pass-phrase a12345678 aes
[AC6605-wlan-sec-prof-wlan-security]quit
创建名为“wlan-ssid”的SSID模板,并配置SSID名称为“wifi-stu”
[AC6605]wlan
[AC6605-wlan-view]ssid-profile name wlan-ssid
[AC6605-wlan-ssid-prof-wlan-ssid]ssid wifi-stu
[AC6605-wlan-ssid-prof-wlan-ssid]quit
创建名为“wlan-vap”的VAP模板,配置业务数据转发模式、业务VLAN,并且引用安全模板和SSID模板。
[AC6605-wlan-view]vap-profile name wlan-vap
[AC6605-wlan-vap-prof-wlan-vap]forward-mode tunnel
[AC6605-wlan-vap-prof-wlan-vap]service-vlan vlan-id 101
[AC6605-wlan-vap-prof-wlan-vap]security-profile wlan-security
[AC6605-wlan-vap-prof-wlan-vap]ssid-profile wlan-ssid
[AC6605-wlan-vap-prof-wlan-vap]quit
配置AP组引用VAP模板,AP上射频0和射频1都使用VAP模板“wlan-vap”的配置。
[AC6605-wlan-view]ap-group name ap-group1
[AC6605-wlan-ap-group-ap-group1]vap-profile wlan-vap wlan 1 radio 0
[AC6605-wlan-ap-group-ap-group1]quit
配置AP射频的信道和功率
[AC6605-wlan-view]ap-id 0
[AC6605-wlan-ap-0]radio 0
[AC6605-wlan-radio-0/0]channel 20mhz 6
[AC6605-wlan-radio-0/0]eirp 127
[AC6605-wlan-radio-0/0]quit