Help needed troubleshooting constant wifi reconnects

Hello,
I am using OpenWRT 19.07.2 on my TP-Link Archer AC1750, and it's generally working quite well, but:

When I want to connect my phone (Motorola Moto G5) to either my 2.4 GHz or 5GHz Wifi, it reconnects every few seconds. This happens only with my phone, other devices behave normal. Also, my phone behaves normal in other networks, so there seems to be a problem together with OpenWRT.

Attached you can find the current wireless configuration (/etc/config/wireless), a logsnippet (logread -f) and a pcap containing the communication between phone and router, captured with airodump-ng on an external device.

Something that caught my interest: When sniffing the communication, airodump reported a high number of lost packeges (roughly 3000), before my phone reconnected.

Thanks for any help or ideas that could lead to a solution, since this situation basically blocks my phone from the wifi.

Haven't figured out how to upload files, here is the config and and the logsnippet as a screenshot...

  • I'm not sure how you "support legacy devices" with the disable eapol retries flag....but OK. Try changing this.
  • You use the </> button in the editor to copy/paste into a codebox for proper display on screen...it's just text.

From the AP or the Phone?

  • sadly, changing this didn't help...

From the Phone. The number actually climbs up to 40,000 in a few seconds, before the Phone reconnects. I believe the high package loss is a problem, but I don't understand why they get lost in the first place. The devices are not even a meter away from each other.
Here is a .pcap of the comunication: moto-tplink-comm.pcap

When a phone is idle, it turns its wifi radio off for long periods of time to save battery power. The AP may or may not handle that gracefully.

If you keep the phone network active for example by streaming audio or video, does it still disconnect?

1 Like

yes, especially in these scenarios. To test if the problem is still there, I start streaming a video... the periods when the phone is connected are really short, 2-3 seconds when there is something happening, maybe 15 when its idling.

I'm not understanding really...but then again you did note that only one device has an issue.

:thinking:

Today I had a look at the logcat output of my Android device, finding this interesting part:

05-13 20:50:52.828  1484 16477 W IpReachabilityMonitor: ALERT: NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
05-13 20:50:52.828  1484 16477 W IpReachabilityMonitor: FAILURE: LOST_PROVISIONING, NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
05-13 20:50:52.831  1484  2099 D WificondControl: get 29 scan results from wificond
05-13 20:50:52.831  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.832  1484  2099 I chatty  : uid=1000(system) WifiScanningSer identical 13 lines
05-13 20:50:52.832  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.832  1484  2037 D WificondControl: get 29 scan results from wificond
05-13 20:50:52.832  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.832  1484  2099 I chatty  : uid=1000(system) WifiScanningSer identical 4 lines
05-13 20:50:52.832  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.832  1484  2037 D WifiStateMachine:  ConnectedState !CMD_IP_REACHABILITY_LOST rt=456246300/812217886 FAILURE: LOST_PROVISIONING, NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
05-13 20:50:52.832  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.832  1484  2037 D WifiStateMachine:  L2ConnectedState !CMD_IP_REACHABILITY_LOST rt=456246300/812217886 FAILURE: LOST_PROVISIONING, NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
05-13 20:50:52.832  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.832  1484  2037 D WifiStateMachine: FAILURE: LOST_PROVISIONING, NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
05-13 20:50:52.832  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.833  1484  2099 I chatty  : uid=1000(system) WifiScanningSer identical 8 lines
05-13 20:50:52.833  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.833 21314 21314 D wpa_supplicant: wlan0: Cancelling scan request
05-13 20:50:52.833  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.833  1484  2099 I chatty  : uid=1000(system) WifiScanningSer identical 1 line
05-13 20:50:52.833  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.833 21314 21314 D wpa_supplicant: wlan0: Request to deauthenticate - bssid=18:d6:c7:61:69:4e pending_bssid=00:00:00:00:00:00 reason=3 state=COMPLETED
05-13 20:50:52.833 21314 21314 D wpa_supplicant: TDLS: Tear down peers
05-13 20:50:52.833  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.833 21314 21314 D wpa_supplicant: wpa_driver_nl80211_disconnect(reason_code=3)
05-13 20:50:52.833  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.836  1484  2099 I chatty  : uid=1000(system) WifiScanningSer identical 48 lines
05-13 20:50:52.836  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159764
05-13 20:50:52.837  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159749
05-13 20:50:52.837  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159767
05-13 20:50:52.837  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159749
05-13 20:50:52.838  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159767
05-13 20:50:52.840  1484  2099 D WifiAsyncChannel.WifiScanningService: sendMessage message=159749
05-13 20:50:52.842  1484  2286 I WifiService: getConfiguredNetworks uid=1000
05-13 20:50:52.842  1484  2286 D WifiAsyncChannel.WifiService: sendMessageSynchronously.send message=131131
05-13 20:50:52.846  1484  3283 D WifiPermissionsUtil: Denied: no location permission
05-13 20:50:52.914   819   904 I SFPerfTracer:      triggers: (rate: 22:699) (8015515 sw vsyncs) (0 skipped) (19:4869896 vsyncs) (21:13042837)
05-13 20:50:52.979 21314 21314 D wpa_supplicant: wlan0: Event DEAUTH (12) received
05-13 20:50:52.979 21314 21314 D wpa_supplicant: wlan0: Deauthentication notification
05-13 20:50:52.979 21314 21314 D wpa_supplicant: wlan0:  * reason 3 (locally generated)
05-13 20:50:52.980 21314 21314 D wpa_supplicant: Deauthentication frame IE(s) - hexdump(len=0): [NULL]
05-13 20:50:52.983 21314 21314 E wpa_supplicant: disconnect rssi= -36
05-13 20:50:52.984 21314 21314 D wpa_supplicant:  notifying disconnect rssi = 36
05-13 20:50:52.984 21314 21314 I wpa_supplicant: wlan0: CTRL-EVENT-DISCONNECTED bssid=18:d6:c7:61:69:4e reason=3 locally_generated=1 disconnect_rssi=36
05-13 20:50:52.984 21314 21314 D wpa_supplicant: wlan0: Auto connect disabled: do not try to re-connect
05-13 20:50:52.984 21314 21314 D wpa_supplicant: wlan0: Ignore connection failure indication since interface has been put into disconnected state
05-13 20:50:52.984 21314 21314 D wpa_supplicant: TDLS: Remove peers on disassociation
05-13 20:50:52.984 21314 21314 D wpa_supplicant: wlan0: WPA: Clear old PMK and PTK
05-13 20:50:52.984 21314 21314 D wpa_supplicant: Notifying disconnect reason to hidl control: -3
05-13 20:50:52.985 21314 21314 D wpa_supplicant: wlan0: Disconnect event - remove keys
05-13 20:50:52.985 21314 21314 D wpa_supplicant: wpa_driver_nl80211_set_key: ifindex=55 (wlan0) alg=0 addr=0x0 key_idx=0 set_tx=0 seq_len=0 key_len=0
05-13 20:50:52.985 21314 21314 D wpa_supplicant: wpa_driver_nl80211_set_key: ifindex=55 (wlan0) alg=0 addr=0x0 key_idx=1 set_tx=0 seq_len=0 key_len=0
05-13 20:50:52.986 21314 21314 D wpa_supplicant: wpa_driver_nl80211_set_key: ifindex=55 (wlan0) alg=0 addr=0xb18520c0 key_idx=0 set_tx=0 seq_len=0 key_len=0
05-13 20:50:52.986 21314 21314 D wpa_supplicant:    addr=18:d6:c7:61:69:4e
05-13 20:50:52.986 21314 21314 D wpa_supplicant: nl80211: Data frame filter flags=0x0
05-13 20:50:52.986 21314 21314 E wpa_supplicant: nl80211: Failed to open /proc/sys/net/ipv4/conf/wlan0/drop_unicast_in_l2_multicast: No such file or directory
05-13 20:50:52.986 21314 21314 E wpa_supplicant: nl80211: Failed to set IPv4 unicast in multicast filter
05-13 20:50:52.986 21314 21314 D wpa_supplicant: wlan0: State: COMPLETED -> DISCONNECTED

Does anyone understand what is happening here? From my understanding, the phone requests a deauthentication due to reason 3, what ever this means?

I would just like to say I have the same issue with my moto g7 play of periodically dropping wifi connection for few seconds maybe 5-10 sec. about every 3-5 min. however I am not running wrt my router is from at&t it days att u-verse
the model number is 5268AC i believe it may be made by "PACE" possibly?? -'_(" ,)_/'-

I had this same issue and tracked it down to a local firewall issue. Follows are the details.

When Android brings up Wi-Fi, it sends IPv6 router solicitations, and my IPv6 router replied including DNS server information (RDNSS). The phone then tried to verify the DNS server by getting it into the neighbor cache by sending some Neighbor Solicitiations, but that DNS server's firewall was misconfigured. It ended up blocking its own ICMPv6 replies. After a few retries it delivered a NUD_FAILED error to the IpReachabilityMonitor and the Wi-Fi interface was restarted, and the whole process loops.

05-13 20:50:52.828  1484 16477 W IpReachabilityMonitor: ALERT: NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
05-13 20:50:52.828  1484 16477 W IpReachabilityMonitor: FAILURE: LOST_PROVISIONING, NeighborEvent{elapsedMs=812217882, fd8c:3f94:b39:0:ba27:ebff:fed3:81bc, [(null)], RTM_NEWNEIGH, NUD_FAILED}
1 Like

Wow, thank you very much, that was the key piece of information that helped me fixing the problem: I had OpenWRT configured to announce an IPv6 DNS Server that didn't exist anymore, but I forgot about the configuration. Simply removing that setting allowed my phone to connect properly.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.