Cisco892W Wireless Settings
勢いで Cisco 892W を買ってしまったので、無線設定のメモを残しておく。
資料
- マニュアル
- 無線設定関連
802W本体設定
ちょっとはまったところだけメモを。
892Wの初期ログインアカウント(User/Pass = Cisco/cisco)はワンタイムアカウントになっていて、初回ログイン時無効化されるので、ログインしたらすぐにアカウント設定を別途やっておかないと次回以降入れなくなってしまう。初回ログイン時に banner でこういう警告が出る。
Username: Cisco Password: % Password expiration warning. ----------------------------------------------------------------------- Cisco Configuration Professional (Cisco CP) is installed on this device and it provides the default username "cisco" for one-time use. If you have already used the username "cisco" to login to the router and your IOS image supports the "one-time" user option, then this username has already expired. You will not be able to login to the router with this username after you exit this session. It is strongly suggested that you create a new username with a privilege level of 15 using the following command. username <myuser> privilege 15 secret 0 <mypassword> Replace <myuser> and <mypassword> with the username and password you want to use. ----------------------------------------------------------------------- yourname#
'the default username "cisco" for one-time use.' ですよ。というのを読み飛ばしてしまって、うっかりタイムアウトさせて1行もコンフィグを入れないうちにパスワードリカバリする羽目に陥ってしまったのでメモを残しておく。
WLAN設定
デバイスの基礎設定
作りとして、箱としてはひとつだけど、中身はルータ本体と無線LANモジュールという2個のデバイスが入っているという構造なので、管理接続用の設定とかが最初に必要になる。
接続モデルとしては
[Router] [AP(ap801)] vlan1 ---+- Wlan-GigabitEthernet0 ----- GigabitEthernet0 --- BVI1 | (WL0) wlan-ap0-+
こんな感じになってると思えばいいのかな…。
wlan-ap0 は IP 振って AP への管理接続に使用する。
interface wlan-ap0 ip address 192.168.253.129 255.255.255.128 ! interface Vlan1 ip address 192.168.253.1 255.255.255.128 !
ルータから "service-module wlan-ap 0 session" とすると、wlan-ap0 の IP に telnet するのだけど、接続先が AP Module になる。あえて IP 振らなくても、
interface wlan-ap0 ip unnumbered vlan1 !
にしておけば vlan1 の IP アドレスで接続できる。ちなみに、line vty で "transport output none" とかルータから他の機器への接続を禁止していると
Router#service-module wlan-ap 0 session % telnet connections not permitted from this terminal
となって AP への接続ができないので注意。今回は "transport output telnet ssh" してしまった。
AP の初回ログインアカウントはルータと同様。ワンタイムになっているところも同様なので、ログインしたらまず banner 表示に従って、アカウント設定を変更する。
Username: Cisco Password: % Password change notice. ----------------------------------------------------------------------- Default username/password setup on AP is cisco/cisco with privilege level 15. It is strongly suggested that you create a new username with privilege level 15 using the following command for console security. username <myuser> privilege 15 secret 0 <mypassword> no username cisco Replace <myuser> and <mypassword> with the username and password you want to use. After you change your username/password you can turn off this message by configuring "no banner login" and "no banner exec" in privileged mode. ----------------------------------------------------------------------- ap#
あとは管理接続用に BVI1 に IP を振ってデフォルトルートを設定しておく。
interface BVI1 ip address 192.168.253.2 255.255.255.128 ! ip default-gateway 192.168.253.1
なお、WLANからルータへ戻る場合は "Control-Shift-6 x" 、ルータ側でさらに "disconnect" する。
無線設定(AP)
- 無線設定
- 5GHz, 2.4GHz でそれぞれひとつの SSID を設定する。
- WPA-PSKを使用する。認証サーバは用意しない(いま手元にないので)。
ということにする。複数 SSID を使う想定なので、SSIDとVLANのひも付けをしてやらなければいけない。今回の無線関連パラメータはこんな感じで設定する。Cisco 800 Series Wireless with multiple SSID - Cisco Support Community においてあるコンフィグが参考になる。
SSID | Freq. | dot1Q(VLAN) | Dot11Radio | Gig0 | DHCP Pool |
---|---|---|---|---|---|
wlan11a | 5GHz | 201 | 1.201 | 0.201 | 192.168.254.16-62/26 |
wlan11bgn | 2.4GHz | 202 | 0.202 | 0.202 | 192.168.254.80-126/26 |
やることは
- SSIDの設定
- Dot11Radio の設定 (VLANごとにサブインタフェースを作る)
- バックボーン側I/F(Gi0)の設定 (VLANごとにサブインタフェースを作る)
コンフィグはこうなる
dot11 ssid wlan11a vlan 201 authentication open authentication key-management wpa guest-mode wpa-psk ascii 0 <pre-shared-key-string> ! dot11 ssid wlan11bgn vlan 202 authentication open authentication key-management wpa guest-mode wpa-psk ascii 0 <pre-shared-key-string> ! ! ! interface Dot11Radio0 no ip address no ip route-cache ! encryption vlan 202 mode ciphers tkip ! ssid wlan11bgn ! antenna gain 0 station-role root bridge-group 1 bridge-group 1 block-unknown-source no bridge-group 1 source-learning no bridge-group 1 unicast-flooding bridge-group 1 spanning-disabled ! interface Dot11Radio0.202 encapsulation dot1Q 202 no ip route-cache bridge-group 202 bridge-group 202 subscriber-loop-control bridge-group 202 block-unknown-source no bridge-group 202 source-learning no bridge-group 202 unicast-flooding bridge-group 202 spanning-disabled ! interface Dot11Radio1 no ip address no ip route-cache ! encryption vlan 201 mode ciphers tkip ! ssid wlan11a ! antenna gain 0 no dfs band block station-role root bridge-group 1 bridge-group 1 block-unknown-source no bridge-group 1 source-learning no bridge-group 1 unicast-flooding bridge-group 1 spanning-disabled ! interface Dot11Radio1.201 encapsulation dot1Q 201 no ip route-cache bridge-group 201 bridge-group 201 subscriber-loop-control bridge-group 201 block-unknown-source no bridge-group 201 source-learning no bridge-group 201 unicast-flooding bridge-group 201 spanning-disabled ! ! ! interface GigabitEthernet0 description the embedded AP GigabitEthernet 0 is an internal interface connecting AP with the host router no ip address no ip route-cache bridge-group 1 no bridge-group 1 source-learning bridge-group 1 spanning-disabled ! interface GigabitEthernet0.201 encapsulation dot1Q 201 no ip route-cache bridge-group 201 no bridge-group 201 source-learning bridge-group 201 spanning-disabled ! interface GigabitEthernet0.202 encapsulation dot1Q 202 no ip route-cache bridge-group 202 no bridge-group 202 source-learning bridge-group 202 spanning-disabled !
Native VLAN 設定とかももちろんできるけど今回は特に使用していない。
無線設定(Router)
やること
ip dhcp excluded-address 192.168.254.0 192.168.254.15 ip dhcp excluded-address 192.168.254.64 192.168.254.79 ! ip dhcp pool wlan11bgn-pool import all network 192.168.254.64 255.255.255.192 default-router 192.168.254.65 dns-server 192.168.2.16 8.8.8.8 ! ip dhcp pool wlan11a-pool import all network 192.168.254.0 255.255.255.192 default-router 192.168.254.1 dns-server 192.168.2.16 8.8.8.8 ! ! ! interface GigabitEthernet0 description WAN(outside) (略) ip nat outside ! interface Vlan1 ip address 192.168.253.1 255.255.255.128 ! interface Vlan201 ip address 192.168.254.1 255.255.255.192 ip nat inside ! interface Vlan202 ip address 192.168.254.65 255.255.255.192 ip nat inside ! interface Wlan-GigabitEthernet0 description Internal switch interface connecting to the embedded AP switchport mode trunk ! ! ! ip nat inside source list 100 interface GigabitEthernet0 overload !
Wlan-GigabitEthernet0 (WL0) はデフォルトだと mode trunk になっていないので注意。
確認
クライアントが無線で接続すると
*Mar 1 11:34:50.505: %DOT11-6-ASSOC: Interface Dot11Radio0, Station 3017.c8XX.XXXX Associated KEY_MGMT[WPA PSK]
みたいな感じで出力される。いま AP に接続しているデバイスの情報は "show dot11 assoc" で確認する。
ap#show dot11 associations 802.11 Client Stations on Dot11Radio0: SSID [wlan11bgn] : MAC Address IP address Device Name Parent State 3017.c8XX.XXXX 192.168.254.80 unknown - self Assoc ap#
ルータ側、DHCPアドレスの払い出しは "show ip dhcp server bindings" で確認する。
Router#show ip dhcp binding Load for five secs: 3%/0%; one minute: 4%; five minutes: 4% Time source is NTP, 19:18:04.600 JST Sun Nov 20 2011 Bindings from all pools not associated with VRF: IP address Client-ID/ Lease expiration Type Hardware address/ User name 192.168.254.80 3017.c8XX.XXXX Nov 21 2011 05:09 PM Automatic 192.168.254.82 0164.80XX.XXXX.48 Nov 21 2011 04:32 PM Automatic Router#