Community discussions

MikroTik App
 
freddi
newbie
Topic Author
Posts: 36
Joined: Sat Oct 27, 2018 1:26 pm

STP active on OSI level 1?

Tue Sep 07, 2021 1:16 pm

Hello,
On our wifi network we recently encountered many interrupts, each one lasting for 15 seconds. They occurred irregularly but very frequently. Sometimes with intervals less than one minute, sometimes 10 minutes.

After I disabled the STP protocol on the Mikrotik switch, the problems disappeared. Disabling this feature did not result in broadcast storms.

The diagram below shows the part of our network having the problems.
The Ubiquiti radio on the left is coupled to the internet, and feeds, via a Miktrotik switch, a point-to-point link, and then to an AP serving a number of clients. These two wifi networks have a different SSID and, normally, operate on the different channel. The client stations on the right are configured as routers, all other stations are configured as bridges on the same subnet.
A radar event caused the channel of the AP_2 to shift to another frequency. Unfortunately the same as the frequency on which the AP_1 operates.
immediately after this DFS event, the radio AP_1 showed the 15 second connectivity drops.

The two wifi networks operate with a different SSID and stations from the SSID_2 network cannot connect to the AP on SSID_1. My understanding was that STP operates at OSI level 2 - the loop, if one would exist, would be on level 1.
Is my understanding incorrect?
You do not have the required permissions to view the files attached to this post.
 
sindy
Forum Guru
Forum Guru
Posts: 10205
Joined: Mon Dec 04, 2017 9:19 pm

Re: STP active on OSI level 1?

Tue Sep 07, 2021 4:50 pm

My understanding was that STP operates at OSI level 2 - the loop, if one would exist, would be on level 1.
Is my understanding incorrect?
STP is an L2 protocol, but it can block forwarding of traffic through a port, which effectively looks like blocking of L1. And STP also reacts to L1 state changes.

When no STA (wireless client) is registered to the AP, from the point of view of STP the situation is the same as if you disconnect a cable from an Ethernet port. So once the first STA connects, STP handles that as if the Ethernet cable got inserted and L1 link went up. From that moment, STP holds the port in "learning" state (as per the MSTP vernacular), where traffic is not forwarded through that port, for some timeout (15 s is a typical value), waiting for eventual BPDUs to arrive; if none arrives during that time, STP assumes that the connected device is not another switch and enables forwarding through that port; if a BPDU arrives, STP re-evaluates the L2 topology taking this BPDU into account and takes a corresponding action.

The above is the behaviour when no port type is specified in configuration. If you set the edge parameter on the corresponding /interface bridge port row to yes, the learning state is skipped and the port goes into forwarding state immediately.

So when you disable STP completely, all ports are always forwarding, and nothing except loop detection packets can detect an eventual loop; if you just set the AP ports as edge ones, you can keep STP in operation to take care about loops on wired ports.
 
freddi
newbie
Topic Author
Posts: 36
Joined: Sat Oct 27, 2018 1:26 pm

Re: STP active on OSI level 1?

Tue Sep 07, 2021 5:41 pm

Thanks for your reply, Sindy.
What I forgot to mention is that STP has been disabled for all Ubiquity bridges in the network. (The stations on the right are configured as routers. wrong icon).

Still I don't understand completely.
The wifi stations in the SSID_2 networks are out of sight from the SSID_1 AP, but I suppose a stray packet can reach that radio from time to time, when they are on the same frequency. But as, their SSID is different the station cannot connect to the AP.
Would such stray packets be able to make it through the AP somehow and enter the Microtik via the LAN to trigger the learning state?
 
sindy
Forum Guru
Forum Guru
Posts: 10205
Joined: Mon Dec 04, 2017 9:19 pm

Re: STP active on OSI level 1?

Tue Sep 07, 2021 8:37 pm

Sorry, I've completely missed that the APs were Ubiquiti ones (on the drawing, only the one to the left from the CRS is explicitly marked as an Ubiquiti one).

So when STP is enabled on the CSS but disabled on the Ubiquiti devices, the 15-second interruptions exist?

If so, could it be that the Ubiquiti APs take the Ethernet side down either while no client is connected to their wireless side or while they change frequency in order to give way to the radar?

The only way I can see how a loop between two ports of the CSS could appear would be that the Ubiquiti STA receiving the internet from the left would register to AP_1. An L1 loop is obviously seen as an L2 loop as well (if you mean the "network" loop, i.e. when a signal sent from one interface is received on another interface of the same device, not a "link loop" where a signal sent from one interface is received on the same interface).

Another possible explanation is that STP is disabled by configuration but if the Ubiquiti devices receive STP BPDUs, they activate STP processing despite what the configuration says.
 
tdw
Forum Guru
Forum Guru
Posts: 1841
Joined: Sat May 05, 2018 11:55 am

Re: STP active on OSI level 1?

Tue Sep 07, 2021 10:51 pm

Ubiquiti APs do not drop the ethernet port when there are no stations or for a DFS event, so not that. They will mesh amongst themselves so if they think ethernet connectivity has been lost they will uplink via other APs wirelessly, offhand I can't remember if this is enabled by default - it may well depend on controller software version too.
 
freddi
newbie
Topic Author
Posts: 36
Joined: Sat Oct 27, 2018 1:26 pm

Re: STP active on OSI level 1?

Wed Sep 08, 2021 5:26 pm

In an attempt to be brief I left out important information. My apologies.
Below an updated picture.

There are three wifi networks involved. Each has its own SSID and channel.
(The cloud represents the rest of out network which is eventually connected to the public internet)
With exception of CPE_4 (rocket) all Ubiquity radios are LiteBeam Gen2, run AirOS, and the links are configured PtMP (even the PtP link between AP_1 and STA_1)
All CPE's have public IP's (185.b.c.0/24). All other systems are on private subnet (10.x.y.0/24)
(Two CPEs have an alias on the 10.x.y.0/24 subnet).

I observed 15 second breaks in connectivity as follows:
1. ping between surveillance system and Mikrotik CSS: No breaks
2. ping between surveillance system and CPE_3: No breaks
3. ping between surveillance system ans AP_1: 15 second breaks
4. ping between surveillance system ans CPE_4: 15 second breaks
5. ping between CPE_4 and 8.8.8.8 15 second breaks

Looking at Cindy's reply I conclude the Mikrotik forces the port connected to AP_1 into learning mode at irregular intevals when the channels of SSID_1 and SSID_2 are the same.
I'm not very familiar with the Spanning Tree Protocol. I'm puzzled as to why the Mikrotik does this.
By the way: from the Airos manual:
STP Multiple interconnected bridges create larger networks using IEEE 802.1d Spanning Tree Protocol (STP), which is used for finding the shortest path within a network and eliminating loops from the topology. If enabled, the device bridge communicates with other network devices by sending and receiving Bridge Protocol Data Units (BPDU). STP should be disabled (default setting) when the device is the only bridge on the LAN or when there are no loops in the topology, as there is no need for the bridge to use STP in this case.
You do not have the required permissions to view the files attached to this post.
Last edited by freddi on Wed Sep 08, 2021 8:25 pm, edited 1 time in total.
 
tdw
Forum Guru
Forum Guru
Posts: 1841
Joined: Sat May 05, 2018 11:55 am

Re: STP active on OSI level 1?

Wed Sep 08, 2021 6:13 pm

My comments reqarding meshing only apply to UniFi, not airOS. Generally it best to leave STP disabled on airOS devices as they only support STP, not RSTP, which takes ages to converge. When STP is disabled they are transparent and pass BPDUs (the same behaviour as a Mikrotik RouterOS bridge with mode=none).

Having the same channels but differing SSIDs should not cause this problem, it will reduce the throughput as STA_1 and AP_2 will interfere with each other. I've not seen any issues in a mixed airMAX/airFiber/nRAY wireless setup with RB3011/hEX PoE devices, maybe something peculiar to SwitchOS on the CSS.
 
User avatar
SiB
Forum Guru
Forum Guru
Posts: 1888
Joined: Sun Jan 06, 2013 11:19 pm
Location: Poland

Re: STP active on OSI level 1?

Sun Sep 12, 2021 12:45 pm

When you have EDGE set at CSS106 then we not should speak about STP...
Seams like that problem was created by Ubnt sub-net segment starting from AP_1.

My recommendation is, put some little NMS like "TheDude" between STA1 and AP_2 for monitoring the left site (AP_1, CSS106. CPE_3) and right site (AP_2, SPE-[4-6]).
Maybe this give you more info where breaks happens.

Who is online

Users browsing this forum: Bing [Bot], Kanzler, kvitek79 and 98 guests