I have a Galaxy S20, which is having a problem with wireless networks (for around a week, maybe a few days more). It will always connect to them fine, but after a certain (somewhat random) amount of time, it will lose network connectivity but still appear to be connected. Sometimes an exclamation mark appears on the icon, sometimes not.
In either case, disabling and then reenabling wifi will fix it, until it drops out again, usually a few minutes later but could be hours later.
I have tested both with my main wireless network (using UniFi APs) and also with an old dd-wrt AP I had lying around. It has the same problem on both although if anything seems to happen more on my main network with much better APs, as well as happening more when I'm actively using the phone rather than just watching a ping command. APs (for my main network, anyway) are running latest firmware, on the best channels (currently 6 and 1) but I have tested other channels. Network is performing fine, DHCP and DNS working properly, etc. DHCP lease time is 12 hours with a static mapping for the phone so I know it's not expiring and failing to renew.
In the logs for the UniFi APs, I get a lot of log entries like this, but search results for them are generally useless:
Dec 14 21:03:32 unifi-1.***** user U7PG2,fcecdaa379ba,v188.8.131.5255: : mcad: wireless_agg_stats.log_sta_anomalies(): bssid=fc:ec:**:**:**:** radio=wifi0 vap=ath0 sta=58:d5:**:**:**:** satisfaction_now=73 anomalies=tcp_latency Dec 14 21:03:50 unifi-1.***** user U7PG2,fcecdaa379ba,v184.108.40.20655: : mcad: wireless_agg_stats.log_sta_anomalies(): bssid=fc:ec:**:**:**:** radio=wifi0 vap=ath0 sta=58:d5:**:**:**:** satisfaction_now=73 anomalies=tcp_latency
When I run a ping to an address on the local network, it works for a while, then stops receiving the replies. Meanwhile, if I ping the phone's IP from a computer, I see a corresponding sudden loss of all packets to the phone (Destination Host Unreachable). The same problem does not occur for any other wireless devices (phones, tablets, or laptops) and happens whether the phone is charging or on battery.
Any idea why this happens or on any fixes? I can do ADB if needed but not sure what to do for diagnostics as android's network tools are fairly limited.
Android version: 10
Patch level: 1 Nov 2020
Kernel: 4.19.81-19654513 #2
Edit: Have kept fiddling with different wireless networks, still having the problem. I have also noticed that if I go into the wifi menu, that is enough to cause it to reconnect and start passing traffic again even if I don't disable/reenable it.