What's new
  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Manual STP settings?

Ceejus

Regular Contributor
I have two Asus routers (one of which is running in AP mode) and a Netgear SX10 switch. As I am running long ethernet cables between all three, I want to have redudancy in case something happens to one of them. As such, I have all three connected in a triangle topology-wise. For the most part, STP works. However, there are times where it does not and the link intended to be the backup (between the AP and the SX10 switch) fails to become an alternate link which results in a loop.

Does anyone know what commands to use to manually set bridge IDs, port priorities, and/or link costs so I don't have to worry about this problem?
 
Sorry, I don't have those routers. You could try using the old brctl commands (e.g. brctl setmaxage br0 30), but looking at this post I'd guess it won't work.
Thanks. Any idea how I might go about at least trying to diagnose this issue? I haven't noticed any particular pattern so it's difficult to guess what might be causing it.
 
Over ssh run
Code:
brctl show
This will display all the bridges with their status. In my case it returns with br0 and br54 (both off).
Next run
Code:
brctl stp brXX on
for each bridge you want stp on, where XX is the bridge number. In my case br0 is my main network, br54 is my guest network. So
Code:
brctl stp br0 on
brctl stp br54 on
It doesn't last long in these newer firmwares so to automatically re-apply the setting periodically I add the following one-liner to /jffs/scripts/service-event
Code:
brctl stp br0 on && brctl stp br54 on
Use "&&" to add as many bridges as you want.
Don' t forget
Code:
chmod a+rx /jffs/scripts/service-event
Once the above is done there's no need to worry - all your selected bridges will have stp active after reboots, but not resets.
It's just a shame the STP setting in the gui does nothing.
 
Last edited:
Over ssh run
Code:
brctl show
This will display all the bridges with their status. In my case it returns with br0 and br54 (both off).
Next run
Code:
brctl stp brXX on
for each bridge you want stp on, where XX is the bridge number. In my case br0 is my main network, br54 is my guest network. So
Code:
brctl stp br0 on
brctl stp br54 on
It doesn't last long in these newer firmwares so to automatically re-apply the setting periodically I add the following one-liner to /jffs/scripts/service-event
Code:
brctl stp br0 on && brctl stp br54 on
Use "&&" to add as many bridges as you want.
Don' t forget
Code:
chmod a+rx /jffs/scripts/service-event
Once the above is done there's no need to worry - all your selected bridges will have stp active after reboots, but not resets.
It's just a shame the STP setting in the gui does nothing.
Wait a second. Doesn't this just do the same as setting STP to on in the GUI? It must do something because STP is working for me as we speak. It's challenging to troubleshoot this issue because if there is a loop, I'm pretty much unable to SSH into anything.

I had considered the possibility that the loop was occurring before STP services could even start up but what's odd is that there are times I let all three (router, AP, and switch) run for a while with the cable between the AP and switch physically disconnected, plug it in, only to find that it causes a loop. This is quite literally a situation where sometimes STP works, sometimes it doesn't.

I'm gathering from the post Colin linked to that Asus has proprietary code that's locking the user's ability to make any manual STP adjustments. If that's the case, that's very unfortunate.
 
Doesn't this just do the same as setting STP to on in the GUI?
Turn stp on in the gui then check it with "stp show"
Doesn't (has never) work with my RT-BE88U with the Merlin 3006 branch. Doesn't work with asus stock firmware either.
 
Turn stp on in the gui then check it with "stp show"
Doesn't (has never) work with my RT-BE88U with the Merlin 3006 branch. Doesn't work with asus stock firmware either.
On my main router, it shows br0 with STP enabled and br58 with STP disabled. On my AP, it shows br0 and br11 (both with completely different bridge IDs than what the router shows) both disabled. And yet... STP is working fine. I'm... confused.
 
I also have a managed switch that has stp enabled. When stp isn't enabled on the router it's restricted to the switch side of the network, and everything works fine there - even if it's disabled upstream (router). It's still disabled and plays no part on the router.
I'm actually surprised to see it showing as active on one of your routers' main network (I guess the pro model?), but not surprised about the guest network. I often wondered if I needed or even wanted it enabled on guest.
It would be interesting if others with BE class routers with stp enabled would post the results of "brctl show" - maybe we could form some kind of correlation to put to asus.
 
Last edited:
I also have a managed switch that has stp enabled. When stp isn't enabled on the router it's restricted to the switch side of the network, and everything works fine there - even if it's disabled upstream (router). It's still disabled and plays no part on the router.
I'm actually surprised to see it showing as active on one of your routers' main network (I guess the pro model?), but not surprised about the guest network. I often wondered if I needed or even wanted it enabled on guest.
It would be interesting if others with BE class routers with stp enabled would post the results of "brctl show" - maybe we could form some kind of correlation to put to asus.
I have to believe there's another loop prevention mechanism at play here on the switch that's not STP then seeing as the alternative link is blocked despite STP apparently not running on the AP. My understanding of STP is that in order for it to work at all, it needs to be running on all switches in the network.
Over ssh run
Code:
brctl show
This will display all the bridges with their status. In my case it returns with br0 and br54 (both off).
Next run
Code:
brctl stp brXX on
for each bridge you want stp on, where XX is the bridge number. In my case br0 is my main network, br54 is my guest network. So
Code:
brctl stp br0 on
brctl stp br54 on
It doesn't last long in these newer firmwares so to automatically re-apply the setting periodically I add the following one-liner to /jffs/scripts/service-event
Code:
brctl stp br0 on && brctl stp br54 on
Use "&&" to add as many bridges as you want.
Don' t forget
Code:
chmod a+rx /jffs/scripts/service-event
Once the above is done there's no need to worry - all your selected bridges will have stp active after reboots, but not resets.
It's just a shame the STP setting in the gui does nothing.
I just took all these steps and manually enabled STP on both the main router and the AP for both the main network and guest network. Will have to see if this solves the issue over the next month or so. Thanks for bringing this to my attention.
 

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Back
Top