OpenWrt not stable

Hello,
I know I ask a lot on this forum. But I have some strange behavior on my openWRT access Point.
it doesn't seem to be stable.
I've set up a wireless bridge to extend my wireless network reach.

but sometimes I have my phone and my laptop connected and on my phone the internet just drops dead and on my laptop it is working. Or the other way around.
like the bridge isn't working.
at other times. in diagnostics all 3 options (ping,tracert,nslookup) fail until a reboot happens.
I'm not completely sure where to start because all looks arbitrary to me.
when it works, the wifi is super,
when it doesn't I'd better can connect my pc directly to the router despite of the poor connection because of the distance.

Is there anythink I can do to make openWrt run more stable?
i've configured both, 2.4 and 5Ghz frequentions.

Hello,
I did some tweaking but my issue still isn't resolved.
however, I found something.
And I will start focussing on the internet connection because I think the rest is related.
when internet fails, (in diagnostics is says: "bad address: 'openwrt.org'") meaning no internet possible, or no dhcp.

what helps most of the time is if I just change one setting in the wireless menu. Like channel from 11 to 13 for master, or the other way around)
and then click "Save & Apply". afterwards my internet connection is working again.
I have the feeling some service fails or crashes and will be restarted when hitting apply.

No my question is, What service should I look for and how can I monitor this.

  • What country are you in...13 isn't avalabie in most nations...
  • Can you show your /etc/config/network and /etc/config/wireless (ofiscuate keys, of course)
1 Like

Hello,

I'm in the Netherlands as you probably also will see in my wireless.
channel 12 and 13 are available here, but some older devices to not support it.
If it's better for debugging I can stay on channels below 12.

my wireless looks like this.

config wifi-device 'radio0'
        option type 'mac80211'
        option channel '36'
        option hwmode '11a'
        option path 'pci0000:00/0000:00:00.0'
        option htmode 'VHT80'
        option country 'NL'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option key '<key>'
        option encryption 'psk2'
        option macfilter 'deny'
        list maclist '18:<ClientMAC>:13'
        option ssid '<masterSSID>'

config wifi-device 'radio1'
        option type 'mac80211'
        option hwmode '11g'
        option path 'platform/ahb/18100000.wmac'
        option htmode 'HT20'
        option country 'NL'
        option channel '12'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option key '<key>'
        option encryption 'psk2'
        option macfilter 'deny'
        list maclist '18:<ClientMAC>:14'
        option ssid '<masterSSID>'

config wifi-iface 'wifinet2'
        option ssid '<clientSSID>'
        option device 'radio0'
        option mode 'sta'
        option key '<key>'
        option network 'wwan'
        option encryption 'psk2'
        option bssid '18:<RouterMAC>:FF'

config wifi-iface 'wifinet3'
        option ssid '<clientSSID>'
        option device 'radio1'
        option mode 'sta'
        option key '<key>'
        option network 'wwan'
        option encryption 'psk2'
        option bssid '18:<RouterMAC>:F9'

at the moment my internet connection and bridge are working. But probably tomorrow or the day after it will suddenly stop working.

  • You are aware that you have 2 STAs listed on 2 bands, correct?
  • You didn't provide the network config as requested, so no clue why you have done so
  • Are you certain that these STAs are hard-set to those channels?

it is indeed correct, 1 on the 2.4Ghz and 1 on the 5Ghz band.
I know, 1 should be enough, but I was expecting this to be more stable.
I forgot the network part, so here it is.

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

config globals 'globals'

config interface 'lan'
        option type 'bridge'
        option ifname 'eth1.1'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option delegate '0'

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

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

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

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

config interface 'wwan'
        option proto 'dhcp'
        option delegate '0'

config interface 'repeater_bridge'
        option proto 'relay'
        option ipaddr '192.168.178.12'
        list network 'lan'
        list network 'wwan'
        option delegate '0'

the sta's are connecting to channels 5 and 44 of my router, those are hard set, but on the router.
op option channels are releted to the master part,
as far as I know at least.

:confused:

You expected 2 equal routes (equal interfaces, different IPs, maybe different MACs, etc.) to the same network - to be stable...?

Ummmmm...nah...that requires advanced config to have two "identical" upstream network connections of any kind (I put in quotes because the purpose of making that advanced config is to change a metric, remove the default route on one interface, etc.).

Do you see a major issue with your statement?

???

Correct, I understood you wanted to bridge anyway. I don't see this in your configs anywhere.

Let's start with fixing these things:

  • Pick one band (and channel) for upstream
  • Set your OpenWrt to match that band and channel
  • You should be able to add the STA config to LAN - this will create your bridge
  • 'repeater_bridge' is a different method I'm not highly familiar with...but it doesn't seem to relate to your needs - given you attempted to use 2.4 and 5.4 to connect to the same upstream network
2 Likes

thank you,
I actually expected it to be stable,
5Ghz is faster, but when not applicable it would have a fallback to 2.4 Ghz,
for not I disabled the 5Ghz.
on another node, I was worried the client and master networks to interfier, so I choose different channels on purpose. But I see they are per adaptor, not per interface.
So I set them to auto and I see, it automatically uses the same channel.
Next to that I noticed the IP was set to dynamic, where it should be set to static. That was an error on my side.
For the relay bridge I followed this manual as suggested on this forum.

I still have it configured this way. But you are suggesting to just only use one "Lan" network?
My network file now looks like this

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

config globals 'globals'

config interface 'lan'
        option type 'bridge'
        option ifname 'eth1.1'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option delegate '0'

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

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

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

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

config interface 'wwan'
        option delegate '0'
        option proto 'static'
        option ipaddr '192.168.178.12'
        option gateway '192.168.178.1'
        list dns '192.168.178.10'
        option netmask '255.255.255.0'

config interface 'repeater_bridge'
        option proto 'relay'
        option ipaddr '192.168.178.12'
        list network 'lan'
        list network 'wwan'
        option delegate '0'

and my wireless file like this:

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

config globals 'globals'

config interface 'lan'
        option type 'bridge'
        option ifname 'eth1.1'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option delegate '0'

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

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

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

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

config interface 'wwan'
        option delegate '0'
        option proto 'static'
        option ipaddr '192.168.178.12'
        option gateway '192.168.178.1'
        list dns '192.168.178.10'
        option netmask '255.255.255.0'

config interface 'repeater_bridge'
        option proto 'relay'
        option ipaddr '192.168.178.12'
        list network 'lan'
        list network 'wwan'
        option delegate '0'

root@OpenWrt:/etc/config# cat wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option hwmode '11a'
        option path 'pci0000:00/0000:00:00.0'
        option htmode 'VHT80'
        option country 'NL'
        option channel 'auto'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option key '<key>'
        option encryption 'psk2'
        option macfilter 'deny'
        list maclist '18:<clientMAC>:13'
        option ssid '<MasterSSID>'

config wifi-device 'radio1'
        option type 'mac80211'
        option hwmode '11g'
        option path 'platform/ahb/18100000.wmac'
        option htmode 'HT20'
        option country 'NL'
        option channel 'auto'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option key '<key>'
        option encryption 'psk2'
        option macfilter 'deny'
        list maclist '18:<clientMAC>:14'
        option ssid '<MasterSSID>'

config wifi-iface 'wifinet2'
        option ssid '<clientSSID>'
        option device 'radio0'
        option mode 'sta'
        option key '<key>'
        option network 'wwan'
        option encryption 'psk2'
        option bssid '18:<routerMAC>:FF'
        option disabled '1'

config wifi-iface 'wifinet3'
        option ssid '<clientSSID>'
        option device 'radio1'
        option mode 'sta'
        option key '<key>'
        option network 'wwan'
        option encryption 'psk2'
        option bssid '18:<routerMAC>:F9'

I actually hope setting the channels to auto will fix my stability issue.

Two STA links will be unstable. Only one can be up at a time and it may flip back and forth, which causes your OpenWrt router's IP address in the main network to change. This will cause loss of Internet access of existing connections using the old IP.

If you have a good 5 GHz signal from the main router use that one as it will be faster. Disable the other one.

Also you have a MAC address blacklisted in the APs, unless you really want to ban some specific user device that is not needed.

A STA interface will search all the channels for its AP then when it connects it will tune the hardware to the upstream AP's channel. This requires any of your APs on the same radio to also operate on that channel. The channel selection in the wifi-device section is not used.

2 Likes

thank you,

I am planning to use the 5Ghz band, but because the 2.4 one has a larger reach I thought I would be better to test with that one.
The listed macadresses in the blocklist are from the accesspoint itself. I'm planning to use the same SSID eventually, and this block is to prevent the AP to connect to itself. But that probably isn't needed anymore because of the BSSID.

ok, I didn't know about this channel thing, I thought a device can operate on multple channels at the same time, but it makes sence it's not possible.

I made some other changes regarding DHCP to the client. and now I hope it keeps working. Now the DHCP from my main network get's forwarded again.

If I still have issues now, I will remove the repeater_bridge, and try to move everything to LAN. and check what that does.

only you can test that, if is appropriate to use 2.4 or 5ghz for sta.

also i don t think this : (openwrt not stable) is the right way to ask for that.

It's smart enough not to do that. Even with the same SSID and no BSSID control, a STA will not internally connect to an AP running on the same radio.

2 Likes

good to know.
thank you verry much,
now it looks like it's running more stable, I still will test for a few days, but I think changing the channel and only having one lan connector enabled did the trick

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