spanning tree protocol
DESCRIPTION
Esta es una presentación que explica en detalle el funcionamiento de STP... de esta hice una traducción, pero el contenido, el modelo en fin la mayoría de información en ella no es de mi autoria. Solo hice traduccion y algunos retoques. Espero la disfruten!TRANSCRIPT
![Page 1: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/1.jpg)
113 Apr 2023 S Ward Abingdon and Witney College
Spanning Tree protocol
CCNA Exploration Semestre 3
Capitulo 5
Spanish
![Page 2: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/2.jpg)
213 Apr 2023 S Ward Abingdon and Witney College
Topics
Redundancia en una Red Convergente Como Spanning Tree Protocol (STP) Elimina
los loops de capa 2 El algoritmo STP y sus 3 pasos Rapid spanning tree protocol (RSPT)
![Page 3: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/3.jpg)
313 Apr 2023 S Ward Abingdon and Witney College
Semester 3
LAN Design
Basic Switch Concepts
VLANs
VTP
STP
Inter-VLAN routing
Wireless
![Page 4: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/4.jpg)
413 Apr 2023 S Ward Abingdon and Witney College
Queremos:
Redundancia en las capas de distribucion y nucleo
Multiples switches y Enlaces troncales
Cuando un enlace falle – otro tome su lugar.
![Page 5: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/5.jpg)
513 Apr 2023 S Ward Abingdon and Witney College
Pero la redundandia da loops!!
Los Loops de conmutacion son un problema si todos los links estan activos:
Tormentas de Broadcast Transmision de multiples tramas Tablas de switch Inconsistentes
![Page 6: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/6.jpg)
613 Apr 2023 S Ward Abingdon and Witney College
Tormenta de broadcast
Envío ARP
request
There’s a switching loop
Inundación de broadcast por un non-source ports
Y esto no hay nada con lo que pueda pararse
![Page 7: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/7.jpg)
713 Apr 2023 S Ward Abingdon and Witney College
Envio de multiples tramas
A B
Envia tramama
a B
A esta a port 3 y No
conoce a B, inunda los
puertos
Trama llega
Y otra Vez
![Page 8: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/8.jpg)
813 Apr 2023 S Ward Abingdon and Witney College
Tabla de switch inconsistente
A B
Send frame to
B
A is on port 3Don’t know B
So flood
A is on port 1A is on port 2
???
A is on port 3A is on port 1A is on port 2
?
![Page 9: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/9.jpg)
913 Apr 2023 S Ward Abingdon and Witney College
Loops por error
Incluso si hay loops no deliberados por redundancia, estos los puede haber por algún error.
![Page 10: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/10.jpg)
1013 Apr 2023 S Ward Abingdon and Witney College
Etherchannel – La excepción
Multiples conecciones no crean un loop donde es usado Etherchannel.
Los links son agregados para actuar como uno solo con ancho de banda combinado.
![Page 11: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/11.jpg)
1113 Apr 2023 S Ward Abingdon and Witney College
Redundancia sin loops
Se necesita tener un solo camino a la vez. Rutas redundantes deben estar apagadas,
pero listas para abrirse cuando se necesite. Esto debe hacerse rapido y
automaticamente.Spanning Tree Protocol hace esto.
![Page 12: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/12.jpg)
1213 Apr 2023 S Ward Abingdon and Witney College
Que es un spanning tree?
Un tree (extended star) topologyUn arbol no tiene loops
Se extiende a todos los dispositivosTodos los dispositivos estan
conectados.
![Page 13: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/13.jpg)
1313 Apr 2023 S Ward Abingdon and Witney College
No es un spanning tree
No es un arbol – tiene loops.
![Page 14: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/14.jpg)
1413 Apr 2023 S Ward Abingdon and Witney College
No es un spanning tree
No expande - Dispositivos fuera
![Page 15: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/15.jpg)
1513 Apr 2023 S Ward Abingdon and Witney College
Es un Spanning tree
Sin loops. Incluye todos los dispositivos
![Page 16: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/16.jpg)
1613 Apr 2023 S Ward Abingdon and Witney College
Spanning tree protocol
Usado por switches para convertir una topologia redundante en un spanning tree.
Desabilita links no deseados bloqueando puertos.
STP es definido por IEEE 802.1d Rapid STP definido por IEEE 802.1w Los Switches correon STP por default – no
necesitan configuracion.
![Page 17: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/17.jpg)
1713 Apr 2023 S Ward Abingdon and Witney College
Algotitmo de Spanning tree
Los switches usan este algoritmo para decidir cuales puertos deben ser apagados.
1. Selecciona un switch para ser “root bridge”
2. Elige un “root port” en cada uno de los otros.
3. Elige un “designated port” en cada segmento
4. Cierra todos los otros puertos.
![Page 18: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/18.jpg)
1813 Apr 2023 S Ward Abingdon and Witney College
Perfil del procesoRoot bridge
Root port
Root port
Root port
Designated portDesignated port
Designated port
Designated port Not chosenClose down
![Page 19: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/19.jpg)
1913 Apr 2023 S Ward Abingdon and Witney College
1 Eleccion del root bridge
Cada switch tiene un bridge ID (BID) de prioridad, seguido por la dirección MAC.
Los Switches intercambian (BPDUs) para comparar los “bridge IDs”
El switch con el mas bajo bridge ID será el “root bridge”
El Administrador puede configurar la prioridad para influir en la selección
![Page 20: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/20.jpg)
2013 Apr 2023 S Ward Abingdon and Witney College
Bridge ID
El bridge ID consiste de bridge priority, extended system ID, y MAC address
Por default la prioridad es 32768 La mas baja prioridad GANA Valor 1 - 65536, multiplos de 4096 Extended system ID identifica las VLANs. Direccion MAC, usada si la prioridad es la
misma. Mejor no confiar en la MAC Address.
![Page 21: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/21.jpg)
2113 Apr 2023 S Ward Abingdon and Witney College
Configurar prioridad
Configurar prioridad directamente SW1#spanning-tree vlan 1 priority 24576 O indirectamente SW1#spanning-tree vlan 1 root primary Pone el valor a 24576 o 4096 menor que la
prioridad mas baja detectada. SW1#spanning-tree vlan 1 root secondary Pone el valor a 28672. Este switch será el root
bridge si el primary root bridge falla.
![Page 22: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/22.jpg)
2213 Apr 2023 S Ward Abingdon and Witney College
1 Eleccion del root bridge
Un switch es iniciado. Este envia tramas BPDUs conteniendo en BID y el root ID cada 2 segundos.
Al principio cada switch se identifica a si mismo como el root bridge.
Si un switch receive un BPDU con un BID mas bajo entonces el identificara a este switch con ese BID como root bridge. El pasara esta informacion en sus propios BPDUs.
Eventualmente todos los switches acordaran que el switch con el menor BID es el root bridge.
![Page 23: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/23.jpg)
2313 Apr 2023 S Ward Abingdon and Witney College
Eleccion de root ports
Cada non-root bridge (Switch) elige un root port Este es el puerto con la ruta de mas bajo costo al
root bridge
![Page 24: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/24.jpg)
2413 Apr 2023 S Ward Abingdon and Witney College
Encontrar el costo de un link
El costo default de los puertos depende de la velocidad del enlace. Establecido por IEEE.
El Costo puede cambiar a medida que se desarrolla Ethernet.
Link speed Revised cost Previous cost
10 Gbps 2 1
1 Gbps 4 1
100 Mbps 19 10
10 Mbps 100 100
![Page 25: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/25.jpg)
2513 Apr 2023 S Ward Abingdon and Witney College
Cambiando el costo de un link
SW1(config)#int fa0/1 SW1(config-if)#spanning-tree cost 25 SW1(config-if)#end
SW1(config)#int fa0/1 SW1(config-if)#no spanning-tree cost SW1(config-if)#end
![Page 26: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/26.jpg)
2613 Apr 2023 S Ward Abingdon and Witney College
Que pasa si los puertos tienen el mismo costo?
Se usa el port priority y el port number. Por default
F0/1 tiene 128.1
F0/2 tiene 128.2
![Page 27: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/27.jpg)
2713 Apr 2023 S Ward Abingdon and Witney College
Configurar port priority
SW2(config-if)#spanning-tree port-priority 112 El Rango en los valores de prioridad 0 - 240,
en incrementos de 16. El valor default port priority es128. El mas bajo valor port priority GANA. El Default port priority es 128. Los puertos que pierden son apagados.
![Page 28: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/28.jpg)
2813 Apr 2023 S Ward Abingdon and Witney College
Pasando informacion de costo
Cada BPDU incluye el costo de la ruta de regreso al root bridge.
The cost es el costo total de todos los links. Como un switch recibe una BPDU, actualiza
el costo mediante la adición en el coste del puerto a través del cual se recibió la BPDU..
![Page 29: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/29.jpg)
2913 Apr 2023 S Ward Abingdon and Witney College
Seleccion del designated ports
En cada segmento, el puerto con ruta de monor costo al root bridge sera el designated port.
![Page 30: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/30.jpg)
3013 Apr 2023 S Ward Abingdon and Witney College
Designated port en costos iguales
Elige el puerto en el switch con el menor bridge ID. Aqui Suponemos que es switch B.
![Page 31: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/31.jpg)
3113 Apr 2023 S Ward Abingdon and Witney College
Inhabilitar Links redundantes
Cualquier puerto que no es root port o designated port es puesto en estado de bloqueo (Blocking)
![Page 32: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/32.jpg)
3213 Apr 2023 S Ward Abingdon and Witney College
BPDU
Los mensajes BPDU son encapsulados en una trama Ethernet.
La MAC address de destino es 01:80:C2:00:00:00, la cual es una direccion de multicast para el spanning-tree group.
![Page 33: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/33.jpg)
3313 Apr 2023 S Ward Abingdon and Witney College
Campos BPDU2 bytes Protocol ID Admin
1 byte Version
1 byte Message type
1 byte Flags
8 bytes Root ID BID and path information4 bytes Cost of path
8 bytes Bridge ID
2 bytes Port ID
2 bytes Message age Timers
2 bytes Max age
2 bytes Hello time
2 bytes Forward delay
![Page 34: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/34.jpg)
3413 Apr 2023 S Ward Abingdon and Witney College
Roles de puertos
STP hace a los puertos: Root ports (forwarding) Designated ports (forwarding) Non-designated ports (shut down)
![Page 35: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/35.jpg)
3513 Apr 2023 S Ward Abingdon and Witney College
Estado de puertos en el Tradicional STP
Blocking – recibe y envia tramas BPDU. Listening – recibe y envia tramas BPDU. Learning – recibe y envia tramas BPDU.
Aprende MAC addresses. Forwarding – Full activo, envia data de
usuario. Disabled – Apagado administrativamente.
Administratively shut down
![Page 36: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/36.jpg)
3613 Apr 2023 S Ward Abingdon and Witney College
Estados y temporizadores
BlockingLoss of BPDU detectedMax-age = 20 sec
BlockingWhen link first comes up
ListeningForward delay = 15 sec
LearningForward delay = 15 sec
Forwarding
Temporizador HELLO, 2 seg. para enviar BPDUs.
Hasta 50 seg. Desde links rotos para volver a enviar.
![Page 37: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/37.jpg)
3713 Apr 2023 S Ward Abingdon and Witney College
Temporizadores BPDU
Los temporizadores están optimizados para una red de 7-switch de diámetro.
La red tiene tiempo de converger antes que los switches envíen data de usuario.
Estos no pueden ser ajustados individual. El diametro puede ser ajustado y esto
cambiara todos los temporizadores.(Mejor No) spanning-tree vlan 1 root primary diameter 5
![Page 38: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/38.jpg)
3813 Apr 2023 S Ward Abingdon and Witney College
Cisco PortFast
Un puerto de acceso que conduce a una estación de trabajo no necesita pasar por los estamos de STP porque no sera apagado.
PortFast le permite al puerto ir directamente desde blocking a forwarding.
Si un switch es conectado mas tarde y el puerto recive un BPDU entonces puede ir a blocking y entonces atravezar por los modos.
![Page 39: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/39.jpg)
3913 Apr 2023 S Ward Abingdon and Witney College
Verificando spanning tree
Root bridge
This switch
![Page 40: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/40.jpg)
4013 Apr 2023 S Ward Abingdon and Witney College
Notificación de cambio de topología (TCN)
Después que la red converge, el root bridge envía BPDUs, pero los otros switches no comúnmente envían BPDUs de regreso.
Si hay un cambio en la topología, los switch envían un BPDU especial llamado (TCN) hacia el root bridge.
Cada switch que recibe el TCN envía un acknowledgement y envía un TCN hacia el root bridge hasta que el root bridge lo recibe.
El root bridge entonces envía BPDUs con el bit de cambio de topología (TC).
![Page 41: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/41.jpg)
4113 Apr 2023 S Ward Abingdon and Witney College
STP developments
Cisco Propietario Per-VLAN spanning
tree protocol (PVST). Per-VLAN spanning
tree protocol plus (PVST+) - supports IEEE 802.1Q
Rapid per-VLAN spanning tree protocol (rapid PVST+)
IEEE Standards Rapid spanning tree
protocol (RSTP) - Multiple STP (MSTP) -
![Page 42: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/42.jpg)
4213 Apr 2023 S Ward Abingdon and Witney College
PVST+
Separados STP para cada VLAN
![Page 43: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/43.jpg)
4313 Apr 2023 S Ward Abingdon and Witney College
PVST+
PVST+ Es la configuracion por defecto de spanning-tree para un switch Catalyst 2960.
La VLAN necesita ser identificada, por lo que cada BID tiene 3 campos: priority, extended system ID, conteniendo el VID, MAC address.
El BID originamnelte solo tiene: Priority+MAC
![Page 44: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/44.jpg)
4413 Apr 2023 S Ward Abingdon and Witney College
Rapid Spanning Tree Protocol
Reemplaza a STP pero compatible con el. Convergencia mas rapida. Misma estructura BPDU, pone 2 en el campo de
version. Envia BPDUs cada 2 segundos. Diferentes roles de puertos y estados. No usa los temporizadores de la misma forma. 3 BPDUs perdidas es tomado como perdida del
enlace. (6 seconds)
![Page 45: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/45.jpg)
4513 Apr 2023 S Ward Abingdon and Witney College
Puerto de borde en RSTP
Un puerto que nunca sera conectado a un switch.
Inmediatamente va a estado forwarding. La misma idea de PortFast de Cisco. Para Configurar un puerto de borde es como
se muestra abajo. spanning-tree portfast Un puerto de borde se convierte en un puerto
normal de spanning-tree si recibe un BPDU
![Page 46: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/46.jpg)
4613 Apr 2023 S Ward Abingdon and Witney College
Tipos de enlaces (Link types)
Un enlace operando en full duplex entre 2 switches es considerado como un enlace point-to-point.
Un enlace operando en half duplex es considerado un shared link (Compartido).
Los puertos en un enlace point-to-point son habiles para cambiar a estado forwarding rapidamente.
![Page 47: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/47.jpg)
4713 Apr 2023 S Ward Abingdon and Witney College
Estados de PuertosOperational STP RSTP
Enabled Blocking Discarding
Enabled Listening Discarding
Enabled Learning Learning
Enabled Forwarding Forwarding
Disabled Disabled Discarding
![Page 48: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/48.jpg)
4813 Apr 2023 S Ward Abingdon and Witney College
Roles de puertos RSTP
Root and designated ports como antes.
Puerto alterno toma lugar si puerto Des fallara.
![Page 49: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/49.jpg)
4913 Apr 2023 S Ward Abingdon and Witney College
Roles de puertos en RSTP
Puerto de Backuptoma su lugar si “root port” falla.
![Page 50: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/50.jpg)
5013 Apr 2023 S Ward Abingdon and Witney College
Roles de puertos en RSTP
Forwarding Root port Designated port
Puerto de borde – no conectar a switch
Discarding Backup port Alternate port Ambos estan
apagados pero listos para trabajar en cualquier momento.
![Page 51: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/51.jpg)
5113 Apr 2023 S Ward Abingdon and Witney College
Consideraciones de diseño
El Root bridge debe ser un switch poderoso en el centro de la red.
Minimizar el numero de puertos que necesiten ser apagados por STP.
Use VTP pruning. (Depuración de VTP) Use switches capa 3 en el core (Núcleo). Mantenga STP corriendo incluso si no hay
puertos que necesiten ser apagados.
![Page 52: Spanning Tree Protocol](https://reader033.vdocuments.us/reader033/viewer/2022052620/5577c9dbd8b42ae0418b47c3/html5/thumbnails/52.jpg)
5213 Apr 2023 S Ward Abingdon and Witney College
The End