What is the easiest way to disable spanning tree on one port of a switch?
The port in question is connecting to non Cisco equipment and we want to disable spanning tree on that port.
Let's assume that the port is in VLAN1.
int fa 0/1
no spanning-tree vlan 1
on an IOS switche.
I don't know any way how to disable spanning tree on a single port of a CatOS switch. It's possible to use "set spantree dis 1" but it disables STP for the whole VLAN.
Yep, we tried that.
It dosen't disable spanning tree just on that interface, it appears in the config as a global command!
If you try it you'll see what I mean.
Yes, you're correct this didn't work. Sorry, I supposed that an interface config command should work on the interface only.
So the only idea on IOS I've got is rootguard. It should prevent STP root from moving to the foreign network. But warning: it would block the port in the case there is a BPDU with lower priority then current root one coming into it, so the result would be network disconnect.
But another idea for CatOS:
Console> (enable) set spantree bpdu-filter 3/4 enable
Warning: Ports enabled with bpdu filter will not send BPDUs and drop all
received BPDUs. You may cause loops in the bridged network if you misuse
Spantree port 3/4 bpdu filter enabled.
I haven't tested this feature but it might work.
What if you had to make that port a part of a different vlan & disable spantree for that vlan ?
Disabling spantree on Cat IOS is a global command or can be done for a particular vlan .
Have you tried set spantree portfast on the port? I may be wrong, but doesn't that command completely disable spanning tree on the port. (not send out or respond to any spanning tree BPDU's?)
The command does not disable spanning tree on the port, but is does force the port into the Forwarding State, which is basically disabling STP. It is not truely disabling Spanning Tree all together, it is just disabling the other Spanning Tree States. This should have the desired results.
Can you shutdown STP on the non-cisco switch port you are connecting to?
If not, Portfast will still recieve the BPDU and still send BPDU packets out the portfast interface.
Here is a very good link for portfast and other commands on Cat IOS
If you use Portfast and BPDU guard, the switch port will be put into a errdisabled state if it recieves a BPDU packet on the portfast interface.
Have you considered letting the non-cisco switches participate in spanning tree?
(Soap Box time) I try to always setup a well documented, designed layer 2 network. If you don't control layer 2, you would be surprised how easy sub optimal paths can be built. Bridging loops can be created and very hard to find without spanning tree...
spanning-tree bpdufilter enable and spanning-tree portfast commands will enable BPDU filtering on an interface. This is the same as disabling spanning tree on a port.
You are correct, it's available since IOS 12.0(5)WC7.
But BPDU filtering is NOT the same as disabling spanning tree on a port.
This is an aswer from "Ask the expert" discussion:
"I always try to be very careful when saying that bpdufilter is disabling the STP on a per-port basis. Bpdu filter just drops inbound/outbound bpdus, it does not removes the instance port. The instance is still running, but this particular port just does not receive/send bpdus and is thus designated forwarding.
If you take the extreme case where all the ports in your instance have been configured for bpdufilter, the instance as well as all its ports are still existing (and still taking memory and cpu). But note that, interestingly, this is different from disabling the instance. If you disable STP for vlan X, ports in vlan X are flooding bpdus instead of dropping them. "