cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3452
Views
35
Helpful
7
Replies

Anyone can explain why portfast can cause loop if it connect to SW?

eigrpy
Level 4
Level 4

Hi We know the portfast port cannot connect to another switch. otherwise it can cause loop. Anyone can explain it ? Thank You

7 Replies 7

Hello. Portfast is bringing port in Up state instantly and it is not waiting for Spanning Tree BPDU-s. So, sometimes it makes loops if you use wrong port for portfast.

Thank you for your reply. 

it is not waiting for Spanning Tree BPDU-s

why this can cause loop? if there is not physical loop, how can it cause the loop between this new switch and the connected switch? 

If there is no actual loop in your topology then portfast can't create one.

But if you have redundant links and one needs blocking by STP if the port begins forwarding immediately there is a potential for a loop and this could well bring your network down.

Jon

Spanning tree makes a tree structure(spanning tree). Suppose there is a one node on the top which is root bridge and all other nodes go to the bottom. You can think of core switch on the top, distribute switches in the middle and lots of access switches. You ususally connect clients to access switches and configure portfast under the interfaces because you want ports to transit to forwarding state immediately.

So far everything is good. Accidently, you connect two switches to each other by mistake.

You see a cable on the ground, then insert it to the outlet on the wall. Other side of the cable is also connected to another outlet on the wall. You have connected two switches.  The structure is not tree anymore. Two branches are connected. If the ports are not portfast, one of them go to block state. But if portfast is configured, ports go to forwarding state and make loop because of the circle you have created.

Masoud

great explanation

There will be no loop, if there is no physical loop in network

Usually, by default,  if there is a portfast enabled and it receives BPDU from smart switch, this port goes down, as there must be no BPDU-s on such port. For cases when you have trunk port and you know that there will be no physical loops, you can use -  spanning-tree portfast trunk command. I usually use it for trunk connections to Routers and Firewalls.

Switch is device that potentially can become reason of loop, if it is not the smart switch and it is not properly configured - for example - basic D-LINK switch. Also, I don't recommend you to use portfasts on Core-Distribution Switches and I am usually using storm-control to stop possible loop on access layer  

Hello,

Irakli answer is correct. I am just adding more information.

When you enable PortFast on a switch or trunk port, the port is immediately transitioned to the spanning tree forwarding state. It may cause loop.

In spaning tree, ports at first go to the listening state and learning state. In this way, based on the configuration and topology, suppose a port must be in block state to avoid loop. If you config portfast on that port, it goes directly to forwarding state and causes loop,

Hope it helps,

Masoud

Review Cisco Networking for a $25 gift card