Edge router x shutdowns/crashs randomly

I have been using OpenWrt for the past 2months, and my router(edge router x) likes to stop/crash and can easily be fixed by unplugging it and then plugging it back in. This problem is very annoying at happens at random times.

Here are some of my configurations

DHCP CONFIG

config dnsmasq
        option domainneeded '1'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.auto'
        option localservice '1'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option dhcpv6 'server'
        option ra 'server'
        option ra_management '1'
        list dhcp_option '6,192.168.1.157'

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'

config host
        option name 'ubuntu'
        option dns '1'
        option ip '192.168.1.157'
        option leasetime 'infinite'
        option mac 'redacted'
        option duid 'redacted'

My firewall configuration

config defaults
        option input 'ACCEPT'
        option output 'ACCEPT'
        option forward 'REJECT'
        option synflood_protect '1'
        option flow_offloading '1'
        option flow_offloading_hw '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'

config rule
        option name 'Allow-DHCP-Renew'
        option src 'wan'
        option proto 'udp'
        option dest_port '68'
        option target 'ACCEPT'
        option family 'ipv4'

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'

config rule
        option name 'Allow-DHCPv6'
        option src 'wan'
        option proto 'udp'
        option src_ip 'fc00::/6'
        option dest_ip 'fc00::/6'
        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'

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'

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'

config include
        option path '/etc/firewall.user'

config include 'miniupnpd'
        option type 'script'
        option path '/usr/share/miniupnpd/firewall.include'
        option family 'any'
        option reload '1'

Network Configuration

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

config globals 'globals'
        option ula_prefix 'redacted'

config interface 'lan'
        option type 'bridge'
        option ifname 'eth0.1'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option ip6assign '60'

config device 'lan_eth0_1_dev'
        option name 'eth0.1'
        option macaddr 'redacted'

config interface 'wan'
        option ifname 'eth0.2'
        option proto 'dhcp'

config device 'wan_eth0_2_dev'
        option name 'eth0.2'
        option macaddr 'redacted'

config interface 'wan6'
        option ifname 'eth0.2'
        option proto 'dhcpv6'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '1 2 3 4 6t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '0 6t'

Check the crash log: cat /sys/kernel/debug/crashlog

List of installed packages? Are you using original power supply? PoE? If so, which one?

1 Like

This file does not exist

I am using the original power supply and my router was working fine before i installed openwrt.

My packages are

base-files - 204.2-r11257-5090152ae3
busybox - 1.30.1-6
cgi-io - 19
collectd - 5.12.0-1
collectd-mod-cpu - 5.12.0-1
collectd-mod-interface - 5.12.0-1
collectd-mod-iwinfo - 5.12.0-1
collectd-mod-load - 5.12.0-1
collectd-mod-memory - 5.12.0-1
collectd-mod-network - 5.12.0-1
collectd-mod-rrdtool - 5.12.0-1
confuse - 3.2.2-1
dnsmasq - 2.80-16.1
dropbear - 2019.78-2
firewall - 2019-11-22-8174814a-3
fstools - 2020-05-12-84269037-1
fwtool - 2
getrandom - 2019-06-16-4df34a4d-3
ip6tables - 1.8.3-1
iptables - 1.8.3-1
iptables-mod-conntrack-extra - 1.8.3-1
iptables-mod-ipopt - 1.8.3-1
jshn - 2020-05-25-66195aee-1
jsonfilter - 2018-02-04-c7e938d6-1
kernel - 4.14.209-1-2e88863ccdd594fb8e842df3c25842ee
kmod-gpio-button-hotplug - 4.14.209-3
kmod-ifb - 4.14.209-1
kmod-ip6tables - 4.14.209-1
kmod-ipt-conntrack - 4.14.209-1
kmod-ipt-conntrack-extra - 4.14.209-1
kmod-ipt-core - 4.14.209-1
kmod-ipt-ipopt - 4.14.209-1
kmod-ipt-nat - 4.14.209-1
kmod-ipt-offload - 4.14.209-1
kmod-ipt-raw - 4.14.209-1
kmod-leds-gpio - 4.14.209-1
kmod-lib-crc-ccitt - 4.14.209-1
kmod-nf-conntrack - 4.14.209-1
kmod-nf-conntrack6 - 4.14.209-1
kmod-nf-flow - 4.14.209-1
kmod-nf-ipt - 4.14.209-1
kmod-nf-ipt6 - 4.14.209-1
kmod-nf-nat - 4.14.209-1
kmod-nf-reject - 4.14.209-1
kmod-nf-reject6 - 4.14.209-1
kmod-ppp - 4.14.209-1
kmod-pppoe - 4.14.209-1
kmod-pppox - 4.14.209-1
kmod-sched-cake - 4.14.209+2019-03-12-057c7388-1
kmod-sched-core - 4.14.209-1
kmod-slhc - 4.14.209-1
libblobmsg-json - 2020-05-25-66195aee-1
libc - 1.1.24-2
libcap - 2.27-1
libelf1 - 0.177-1
libgcc1 - 7.5.0-2
libgd - 2.2.5-2
libip4tc2 - 1.8.3-1
libip6tc2 - 1.8.3-1
libiwinfo-lua - 2019-10-16-07315b6f-1
libiwinfo20181126 - 2019-10-16-07315b6f-1
libjpeg - 9c-2
libjson-c2 - 0.12.1-3.1
libjson-script - 2020-05-25-66195aee-1
libltdl7 - 2.4.6-2
liblua5.1.5 - 5.1.5-3
liblucihttp-lua - 2019-07-05-a34a17d5-1
liblucihttp0 - 2019-07-05-a34a17d5-1
libmnl0 - 1.0.4-2
libncurses6 - 6.1-5
libnl-core200 - 3.4.0-2
libnl-route200 - 3.4.0-2
libnl-tiny - 0.1-5
libpng - 1.6.37-3
libpthread - 1.1.24-2
librrd1 - 1.0.50-3
librt - 1.1.24-2
libubox20191228 - 2020-05-25-66195aee-1
libubus-lua - 2019-12-27-041c9d1c-1
libubus20191227 - 2019-12-27-041c9d1c-1
libuci20130104 - 2019-09-01-415f9e48-4
libuclient20160123 - 2020-06-17-51e16ebf-1
libxtables12 - 1.8.3-1
logd - 2019-06-16-4df34a4d-3
lua - 5.1.5-3
luci - git-20.341.57626-51f55b5-1
luci-app-firewall - git-20.341.57626-51f55b5-1
luci-app-opkg - git-20.341.57626-51f55b5-1
luci-app-sqm - 1.4.0-2
luci-app-vnstat - git-21.013.43456-fa0c7c0-1
luci-base - git-20.341.57626-51f55b5-1
luci-compat - git-20.364.45011-a04ce80-1
luci-lib-ip - git-20.341.57626-51f55b5-1
luci-lib-iptparser - git-21.013.43456-fa0c7c0-1
luci-lib-jsonc - git-20.341.57626-51f55b5-1
luci-lib-nixio - git-20.341.57626-51f55b5-1
luci-mod-admin-full - git-20.341.57626-51f55b5-1
luci-mod-network - git-20.341.57626-51f55b5-1
luci-mod-status - git-20.341.57626-51f55b5-1
luci-mod-system - git-20.341.57626-51f55b5-1
luci-proto-ipv6 - git-20.341.57626-51f55b5-1
luci-proto-ppp - git-20.341.57626-51f55b5-1
luci-theme-bootstrap - git-20.341.57626-51f55b5-1
mtd - 24
netifd - 2019-08-05-5e02f944-1
odhcp6c - 2019-01-11-e199804b-16
odhcpd-ipv6only - 2020-05-03-49e4949c-3
openwrt-keyring - 2019-07-25-8080ef34-1
opkg - 2020-05-07-f2166a89-1
ppp - 2.4.7.git-2019-05-25-3
ppp-mod-pppoe - 2.4.7.git-2019-05-25-3
procd - 2020-03-07-09b9bd82-1
rpcd - 2020-05-26-67c8a3fd-1
rpcd-mod-file - 2020-05-26-67c8a3fd-1
rpcd-mod-iwinfo - 2020-05-26-67c8a3fd-1
rpcd-mod-luci - 20201107
rpcd-mod-rrdns - 20170710
rrdtool1 - 1.0.50-3
sqm-scripts - 1.4.0-2
swconfig - 12
tc - 5.0.0-2.1
terminfo - 6.1-5
ubi-utils - 2.1.1-1
ubox - 2019-06-16-4df34a4d-3
ubus - 2019-12-27-041c9d1c-1
ubusd - 2019-12-27-041c9d1c-1
uci - 2019-09-01-415f9e48-4
uclient-fetch - 2020-06-17-51e16ebf-1
uhttpd - 2020-10-01-3abcc891-1
urandom-seed - 1.0-1
urngd - 2020-01-21-c7f7b6b6-1
usign - 2020-05-23-f1f65026-1
vnstat - 1.18-2
vnstati - 1.18-2
zlib - 1.2.11-3
ubus call system board; free; uptime
1 Like

I receive this output

{
        "kernel": "4.14.209",
        "hostname": "OpenWrt",
        "system": "MediaTek MT7621 ver:1 eco:3",
        "model": "UBNT-ERX",
        "board_name": "ubnt-erx",
        "release": {
                "distribution": "OpenWrt",
                "version": "19.07.5",
                "revision": "r11257-5090152ae3",
                "target": "ramips/mt7621",
                "description": "OpenWrt 19.07.5 r11257-5090152ae3"
        }
}
              total        used        free      shared  buff/cache   available
Mem:         253716       25276      220764         308        7676      200864
Swap:             0           0           0
 09:27:04 up  5:23,  load average: 0.02, 0.05, 0.06
1 Like

The hardware offloading makes my Netgear R6220 (also MediaTek MT7621) unstable.

Works fine on my ERX. I'm still limited to about 300 Mbits/sec tho, could be my uplink, not hw.

Maybe go back to factory and re-test? Were you on EdgeOS 2.x or 1.x before you installed OpenWrt? I'm a relatively new ERX user and I went from 2.x to OpenWrt 19.07 and knock on wood haven't had any issues.

I went from EdgeOS 2.x to 18.xx and then sysupgraded. And yes my router was completely fine on edgeos openwrt is cause the problems.

I turned this off a couple of hours ago and now my router shuts down every hour. Worst experience ever with custom router firmware.

Running fine and stable for me, on self compiled package

{
        "kernel": "5.4.94",
        "hostname": "edge_MK_Openwrt",
        "system": "MediaTek MT7621 ver:1 eco:3",
        "model": "Ubiquiti EdgeRouter X",
        "board_name": "ubnt,edgerouter-x",
        "release": {
                "distribution": "OpenWrt",
                "version": "SNAPSHOT",
                "revision": "r3012+12656-0d1b329914",
                "target": "ramips/mt7621",
                "description": "OpenWrt SNAPSHOT r3012+12656-0d1b329914"
        }
}

PM in case of interest for the firmware - but as you know, there is o warranty. Also as you have previous 4.x Kernel, I would strongly advice to perform configuration reset if you will choose to upgrade.

I found out that my router is not restarting, it is assigning IP addresses that are not in my range.
Usually, I get ips between 192.168.1.0-192.168.1.255 but my devices are getting assigned random ips like 169.254.211.154 or 169.254.13.235.