Random disconnection from WiFi

I am using 802.11ac/n for airlink oculus. During use, after 10 minutes, the device disconnects from Wi-Fi, the router does not reboot, but simply disconnect device, I do not know what to do with it. The distance to the router is less than 2 meters, the channel is occupied only to my network.

Router: Mi Router 4a gigabit v.2
Firmware: OpenWRT 23.05.3

Thu Jul 11 11:27:52 2024 daemon.info hostapd: phy1-ap0: STA b4:17:a8:fb:b5:aa IEEE 802.11: authenticated
Thu Jul 11 11:27:52 2024 daemon.info hostapd: phy1-ap0: STA b4:17:a8:fb:b5:aa IEEE 802.11: associated (aid 1)
Thu Jul 11 11:27:53 2024 daemon.notice hostapd: phy1-ap0: AP-STA-CONNECTED b4:17:a8:fb:b5:aa auth_alg=open
Thu Jul 11 11:27:53 2024 daemon.info hostapd: phy1-ap0: STA b4:17:a8:fb:b5:aa WPA: pairwise key handshake completed (RSN)
Thu Jul 11 11:27:53 2024 daemon.notice hostapd: phy1-ap0: EAPOL-4WAY-HS-COMPLETED b4:17:a8:fb:b5:aa
Thu Jul 11 11:27:53 2024 daemon.info dnsmasq-dhcp[1]: DHCPREQUEST(br-lan) 192.168.1.111 b4:17:a8:fb:b5:aa
Thu Jul 11 11:27:53 2024 daemon.info dnsmasq-dhcp[1]: DHCPACK(br-lan) 192.168.1.111 b4:17:a8:fb:b5:aa
Thu Jul 11 11:27:53 2024 daemon.warn odhcpd[1522]: No default route present, overriding ra_lifetime!
Thu Jul 11 11:30:45 2024 daemon.warn odhcpd[1522]: No default route present, overriding ra_lifetime!
Thu Jul 11 11:34:26 2024 daemon.notice hostapd: phy1-ap0: AP-STA-DISCONNECTED b4:17:a8:fb:b5:aa

Please connect to your OpenWrt device using ssh and copy the output of the following commands and post it here using the "Preformatted text </> " button:
grafik
Remember to redact passwords, MAC addresses and any public IP addresses you may have:

ubus call system board
cat /etc/config/network
cat /etc/config/wireless
cat /etc/config/dhcp
cat /etc/config/firewall

ubus call system board

{
        "kernel": "5.15.150",
        "hostname": "OpenWrt",
        "system": "MediaTek MT7621 ver:1 eco:3",
        "model": "Xiaomi Mi Router 4A Gigabit Edition v2",
        "board_name": "xiaomi,mi-router-4a-gigabit-v2",
        "rootfs_type": "squashfs",
        "release": {
                "distribution": "OpenWrt",
                "version": "23.05.3",
                "revision": "r23809-234f1a2efa",
                "target": "ramips/mt7621",
                "description": "OpenWrt 23.05.3 r23809-234f1a2efa"
        }
}

cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option ula_prefix 'fdc6:f96c:af7c::/48'
        option packet_steering '1'

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'lan1'
        list ports 'lan2'

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option ip6assign '60'

config interface 'wan'
        option device 'wan'
        option proto 'dhcp'

config interface 'wan6'
        option device 'wan'
        option proto 'dhcpv6'

cat /etc/config/wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0'
        option channel '1'
        option band '2g'
        option htmode 'HT20'
        option disabled '1'

config wifi-device 'radio1'
        option type 'mac80211'
        option path '1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0'
        option channel '157'
        option band '5g'
        option htmode 'VHT80'
        option cell_density '0'
        option country '00'

config wifi-iface 'wifinet0'
        option device 'radio1'
        option mode 'ap'
        option ssid '***'
        option encryption 'psk-mixed'
        option key '***'
        option network 'lan'
        option disassoc_low_ack '0'

cat /etc/config/dhcp

config dnsmasq
        option domainneeded '1'
        option boguspriv '1'
        option filterwin2k '0'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option nonegcache '0'
        option cachesize '1000'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.d/resolv.conf.auto'
        option nonwildcard '1'
        option localservice '1'
        option ednspacket_max '1232'
        option filter_aaaa '0'
        option filter_a '0'
        option confdir '/tmp/dnsmasq.d'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv4 'server'
        option dhcpv6 'server'
        option ra 'server'
        option ra_slaac '1'
        list ra_flags 'managed-config'
        list ra_flags 'other-config'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'

cat /etc/config/firewall

config defaults
        option syn_flood        1
        option input            REJECT
        option output           ACCEPT
        option forward          REJECT
# Uncomment this line to disable ipv6 rules
#       option disable_ipv6     1

config zone
        option name             lan
        list   network          'lan'
        option input            ACCEPT
        option output           ACCEPT
        option forward          ACCEPT

config zone
        option name             wan
        list   network          'wan'
        list   network          'wan6'
        option input            REJECT
        option output           ACCEPT
        option forward          REJECT
        option masq             1
        option mtu_fix          1

config forwarding
        option src              lan
        option dest             wan

# We need to accept udp packets on port 68,
# see https://dev.openwrt.org/ticket/4108
config rule
        option name             Allow-DHCP-Renew
        option src              wan
        option proto            udp
        option dest_port        68
        option target           ACCEPT
        option family           ipv4

# Allow IPv4 ping
config rule
        option name             Allow-Ping
        option src              wan
        option proto            icmp
        option icmp_type        echo-request
        option family           ipv4
        option target           ACCEPT

config rule
        option name             Allow-IGMP
        option src              wan
        option proto            igmp
        option family           ipv4
        option target           ACCEPT

# Allow DHCPv6 replies
# see https://github.com/openwrt/openwrt/issues/5066
config rule
        option name             Allow-DHCPv6
        option src              wan
        option proto            udp
        option dest_port        546
        option family           ipv6
        option target           ACCEPT

config rule
        option name             Allow-MLD
        option src              wan
        option proto            icmp
        option src_ip           fe80::/10
        list icmp_type          '130/0'
        list icmp_type          '131/0'
        list icmp_type          '132/0'
        list icmp_type          '143/0'
        option family           ipv6
        option target           ACCEPT

# Allow essential incoming IPv6 ICMP traffic
config rule
        option name             Allow-ICMPv6-Input
        option src              wan
        option proto    icmp
        list icmp_type          echo-request
        list icmp_type          echo-reply
        list icmp_type          destination-unreachable
        list icmp_type          packet-too-big
        list icmp_type          time-exceeded
        list icmp_type          bad-header
        list icmp_type          unknown-header-type
        list icmp_type          router-solicitation
        list icmp_type          neighbour-solicitation
        list icmp_type          router-advertisement
        list icmp_type          neighbour-advertisement
        option limit            1000/sec
        option family           ipv6
        option target           ACCEPT

# Allow essential forwarded IPv6 ICMP traffic
config rule
        option name             Allow-ICMPv6-Forward
        option src              wan
        option dest             *
        option proto            icmp
        list icmp_type          echo-request
        list icmp_type          echo-reply
        list icmp_type          destination-unreachable
        list icmp_type          packet-too-big
        list icmp_type          time-exceeded
        list icmp_type          bad-header
        list icmp_type          unknown-header-type
        option limit            1000/sec
        option family           ipv6
        option target           ACCEPT

config rule
        option name             Allow-IPSec-ESP
        option src              wan
        option dest             lan
        option proto            esp
        option target           ACCEPT

config rule
        option name             Allow-ISAKMP
        option src              wan
        option dest             lan
        option dest_port        500
        option proto            udp
        option target           ACCEPT

Set your country code properly, and then select a channel that will not be in the DFS range. (see the table in this article). You may also want to go back to 40MHz channels to ensure that you have good signal performance.

Don't use psk-mixed. Try normal wpa2 (psk2) instead.

Then reboot and test again.

1 Like

After a day of testing, this problem still remains, I think it's overheating of the router
p.s also, the speed over the cable dropped to 70 megabits, I'm sure it's not about the provider, since this router is my second, the speed from the first is normal

Thermal or power issues could certainly play a part. Do you have a small desk fan you can point at the router?

1 Like

I bought larger radiators than standard ones, smeared thermal paste, but even so, the temperatures of the radiators themselves are high, so that it would be about understanding to hold your finger on it for more than 2-3 seconds already burns. I'll try to attach a fan

Make sure you applied the thermal compound correctly. Too think can be counter productive, as can too thin. A desk fan simply blowing over the system may be sufficient, but a proper case mounted fan could be good, too, provided that there is enough air exchange.