BPI-R2 OpenWRT 4.14.75 - trouble with wifi


#1

Hi all! I have some trouble with wifi interface in AP mode and two or more clients connected. I got source from bpir2wrt, my config. With one wifi client all works perfect, but when second client connects and both begin to generate traffic (I have samba server), speed slows down to 0. When I trying to reconnect to wifi, I have this output:

hostapd -dd /etc/hostapd.conf
`root@OpenWrt:~# hostapd -dd /etc/hostapd.conf                                                                                                                                                                      
Configuration file: /etc/hostapd.conf
Using interface mtkap0 with hwaddr 02:08:22:6e:7d:41 and ssid "bpitest"
mtkap0: interface state UNINITIALIZED->ENABLED
mtkap0: AP-ENABLED 
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.11: associated
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: event 1 notification
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: start authentication
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: unauthorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (4/4 Pairwise)
mtkap0: AP-STA-CONNECTED 8c:1a:bf:17:ba:4f
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: authorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: pairwise key handshake completed (RSN)
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.11: associated
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 1 notification
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: start authentication
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (4/4 Pairwise)
mtkap0: AP-STA-CONNECTED 3c:f8:62:e0:fd:2b
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: authorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: pairwise key handshake completed (RSN)
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.11: disassociated
mtkap0: AP-STA-DISCONNECTED 3c:f8:62:e0:fd:2b
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 2 notification
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.11: disassociated
mtkap0: AP-STA-DISCONNECTED 8c:1a:bf:17:ba:4f
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: event 2 notification
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.11: associated
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 1 notification
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: start authentication
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: PTKSTART: Retry limit 4 reached
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 3 notification
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b MLME: MLME-DEAUTHENTICATE.indication(3c:f8:62:e0:fd:2b, 2)
mtkap0: STA 3c:f8:62:e0:fd:2b MLME: MLME-DELETEKEYS.request(3c:f8:62:e0:fd:2b)
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.11: disassociated
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 2 notification
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.11: associated
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 1 notification
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: start authentication
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: EAPOL-Key timeout
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: PTKSTART: Retry limit 4 reached
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 3 notification
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b MLME: MLME-DEAUTHENTICATE.indication(3c:f8:62:e0:fd:2b, 2)
mtkap0: STA 3c:f8:62:e0:fd:2b MLME: MLME-DELETEKEYS.request(3c:f8:62:e0:fd:2b)
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.11: disassociated
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: event 2 notification
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: unauthorizing port`

In dmesg nothhing happens.

hostapd.conf:

ssid=bpites
wpa_passphrase=testtest123
interface=mtkap0
bridge=br-lan
auth_algs=1
channel=4
driver=nl80211
wpa=2
wpa_key_mgmt=WPA-PSK
hw_mode=g
wpa_pairwise=CCMP
utf8_ssid=1

Ofcource before run hostapd “stp_uart_launcher -p /etc/firmware/ &” and “echo A > /dev/wmtWifi” were done. P.S. Sorry for my english =)


(Frank W.) #2

Can you try this settings:

wpa=2
wpa_key_mgmt=WPA-PSK
rsn_pairwise=CCMP
wpa_group_rekey=600
wpa_ptk_rekey=600
wpa_gmk_rekey=86400

#3

Looks like fixed, but…

hostapd output
mtkap0: AP-STA-CONNECTED 8c:1a:bf:17:ba:4f
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: authorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: pairwise key handshake completed (RSN)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: rekeying PTK
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (4/4 Pairwise)
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: authorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: pairwise key handshake completed (RSN)
mtkap0: WPA rekeying GTK
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 1/2 msg of Group Key Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/2 msg of Group Key Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (2/2 Group)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: group key handshake completed (RSN)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (2/2 Group)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: group key handshake completed (RSN)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: rekeying PTK
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (4/4 Pairwise)
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: authorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: pairwise key handshake completed (RSN)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: rekeying PTK
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (4/4 Pairwise)
mtkap0: STA 3c:f8:62:e0:fd:2b IEEE 802.1X: authorizing port
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: pairwise key handshake completed (RSN)
mtkap0: WPA rekeying GTK
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 1/2 msg of Group Key Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: sending 1/2 msg of Group Key Handshake
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: received EAPOL-Key frame (2/2 Group)
mtkap0: STA 3c:f8:62:e0:fd:2b WPA: group key handshake completed (RSN)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (2/2 Group)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: group key handshake completed (RSN)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: rekeying PTK
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: EAPOL-Key timeout
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: EAPOL-Key timeout
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: EAPOL-Key timeout
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: EAPOL-Key timeout
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: PTKINITNEGOTIATING: Retry limit 4 reached
mtkap0: AP-STA-DISCONNECTED 8c:1a:bf:17:ba:4f
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: event 3 notification
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: unauthorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f MLME: MLME-DEAUTHENTICATE.indication(8c:1a:bf:17:ba:4f, 2)
mtkap0: STA 8c:1a:bf:17:ba:4f MLME: MLME-DELETEKEYS.request(8c:1a:bf:17:ba:4f)
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.11: disassociated
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: event 2 notification
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: unauthorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.11: associated
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: event 1 notification
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: start authentication
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: unauthorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 1/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (2/4 Pairwise)
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: sending 3/4 msg of 4-Way Handshake
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: received EAPOL-Key frame (4/4 Pairwise)
mtkap0: AP-STA-CONNECTED 8c:1a:bf:17:ba:4f
mtkap0: STA 8c:1a:bf:17:ba:4f IEEE 802.1X: authorizing port
mtkap0: STA 8c:1a:bf:17:ba:4f WPA: pairwise key handshake completed (RSN)

Android smartphone got reconnect while download file and shown error, netbook is still downloading file. Repeated it 3 times. I dont know, may be it’s already android issue? But thanks a lot, now I dont need to reboot bpi or kill hostapd and doing echo 0 > /dev/wmtWifi and run all over again.


(Frank W.) #4

You can play around with values of rekey-options


#5

Thanks, Frank! I was surprised what it’s no hardware/driver problem.

Now I going to learn about options in hostapd.conf and common work of wi-fi :smile:


(Frank W.) #6

i did not said thats a driver/hw-problem…it’s not the best wifi-chip and not the best driver. but you can try to minimize your affection with it by a bit finetuning.

better hardware/drivers do this finetuning automaticly