|  | 
 
| 根据帖子http://armbbs.net/forum.php?mod=viewthread&tid=14602&highlight=wpa%2B%2Bwifi,执行命令:wpa_supplicant  -Dwext -iwlan0 -c/etc/wpa_supplicant.conf  -dd& 是成功的,但是执行动态分配IP就不行:udhcpc -b -i wlan0   代码截图如下: wpa_driver_wext_set_key: alg=2 key_idx=1 set_tx=0 seq_len=6 key_len=32
 WPA: Sending EAPOL-Key 2/2
 WPA: TX EAPOL-Key - hexdump(len=99): 01 03 00 5f fe 03 11 00 20 00 00 00 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 b2 78 8f 54 9e 41 4d ad 00 4a 88 f7 cd 43 13 d4 00 00
 WPA: Key negotiation completed with c0:61:18:f0:a8:cc [PTK=TKIP GTK=TKIP]
 Cancelling authentication timeout
 State: GROUP_HANDSHAKE -> COMPLETED
 CTRL-EVENT-CONNECTED - Connection to c0:61:18:f0:a8:cc completed (auth) [id=0 id_str=]
 wpa_driver_wext_set_operstate: operstate 0->1 (UP)
 netlink: Operstate: linkmode=-1, operstate=6
 EAPOL: External notification - portValid=1
 EAPOL: External notification - EAP success=1
 EAPOL: SUPP_PAE entering state AUTHENTICATING
 EAPOL: SUPP_BE entering state SUCCESS
 EAP: EAP entering state DISABLED
 EAPOL: SUPP_PAE entering state AUTHENTICATED
 EAPOL: Supplicant port status: Authorized
 EAPOL: SUPP_BE entering state IDLE
 EAPOL authentication completed successfully
 RTM_NEWLINK: operstate=1 ifi_flags=0x11043 ([UP][RUNNING][LOWER_UP])
 RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
 EAPOL: startWhen --> 0
 EAPOL: disable timer tick
 
 
 [root@EmbedSky /]# udhcpc -b -i wlan0
 udhcpc (v1.18.5) started
 Setting IP address 0.0.0.0 on wlan0
 Sending discover...
 Sending discover...
 Sending discover...
 No lease, forking to background
 [root@EmbedSky /]# ifconfig
 lo        Link encap:Local Loopback
 inet addr:127.0.0.1  Mask:255.0.0.0
 inet6 addr: ::1/128 Scope:Host
 UP LOOPBACK RUNNING  MTU:16436  Metric:1
 RX packets:0 errors:0 dropped:0 overruns:0 frame:0
 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
 collisions:0 txqueuelen:0
 RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
 
 
 wlan0     Link encap:Ethernet  HWaddr 00:27:13:ED:2A:DB
 inet6 addr: fe80::227:13ff:feed:2adb/64 Scope:Link
 UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
 RX packets:4 errors:0 dropped:0 overruns:0 frame:0
 TX packets:11 errors:0 dropped:0 overruns:0 carrier:0
 collisions:0 txqueuelen:1000
 RX bytes:638 (638.0 B)  TX bytes:1475 (1.4 KiB)
 
 
 [root@EmbedSky /]#
 
 
 静态分配IP是可以的,能够连接上外网,截图如下:
 WPA: RSC - hexdump(len=6): 00 00 00 00 00 00
 wpa_driver_wext_set_key: alg=2 key_idx=1 set_tx=0 seq_len=6 key_len=32
 WPA: Sending EAPOL-Key 2/2
 WPA: TX EAPOL-Key - hexdump(len=99): 01 03 00 5f fe 03 11 00 20 00 00 00 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 a1 37 06 7a b9 2d 16 40 1f 04 aa 37 a7 62 76 ec 00 00
 WPA: Key negotiation completed with c0:61:18:f0:a8:cc [PTK=TKIP GTK=TKIP]
 Cancelling authentication timeout
 State: GROUP_HANDSHAKE -> COMPLETED
 CTRL-EVENT-CONNECTED - Connection to c0:61:18:f0:a8:cc completed (auth) [id=0 id_str=]
 wpa_driver_wext_set_operstate: operstate 0->1 (UP)
 netlink: Operstate: linkmode=-1, operstate=6
 EAPOL: External notification - portValid=1
 EAPOL: External notification - EAP success=1
 EAPOL: SUPP_PAE entering state AUTHENTICATING
 EAPOL: SUPP_BE entering state SUCCESS
 EAP: EAP entering state DISABLED
 EAPOL: SUPP_PAE entering state AUTHENTICATED
 EAPOL: Supplicant port status: Authorized
 EAPOL: SUPP_BE entering state IDLE
 EAPOL authentication completed successfully
 RTM_NEWLINK: operstate=1 ifi_flags=0x11043 ([UP][RUNNING][LOWER_UP])
 RTM_NEWLINK, IFLA_IFNAME: Interface 'wlan0' added
 EAPOL: startWhen --> 0
 EAPOL: disable timer tick
 
 [root@EmbedSky /]# cat etc/resolv.conf
 nameserver 219.233.241.166
 nameserver 211.167.97.67
 [root@EmbedSky /]# ifconfig wlan0 192.168.1.22
 [root@EmbedSky /]# route add default gw 192.168.1.2
 [root@EmbedSky /]# route add default gw 192.168.1.1
 [root@EmbedSky /]# ping 192.168.1.1
 PING 192.168.1.1 (192.168.1.1): 56 data bytes
 64 bytes from 192.168.1.1: seq=0 ttl=64 time=4.635 ms
 64 bytes from 192.168.1.1: seq=1 ttl=64 time=2.463 ms
 ^C
 --- 192.168.1.1 ping statistics ---
 2 packets transmitted, 2 packets received, 0% packet loss
 
 
 这到底什么情况啊,恳请遇到这种问题的同仁不吝赐教!
 
 | 
 |