lunes, 26 de agosto de 2013

Routing on a Stick


Este artículo forma parte de una serie de varios artículos que tratan los distintos tipos de routing en IPV4 e IPV6 para CCNA R&S, para ir al índice del curso tienes este link:

 Routing on a Stick


Routing on a stick es un tipo de topología bastante empleada para hacer routing entre diferentes vlanes desde un único router. En realidad no es el método mas utilizado para hacer routing entre vlanes, pero se usa mucho, y cualquier técnico debería dominar ambos método.

Por medio de routing on a stick, un router configurará una interfaz para etiquetar paquetes con 802.1q, y esta interfaz irá conectada a un switch con el puerto configurado como trunk y encapsulación 802.1q.

El router con ello creará subinterfaces lógicas en cada una de las vlanes, y podrá enrrutar el tráfico al igual que en el artículo sobre routing estático 1 en el router 2.

Configuración:


R(config-if)#int fa0/0.<Numero que quieras habitualmente el número de vlan>

R(config-subif)#encapsulation dot1Q <numero_vlan>

R(config-subif)#ip add <IP> <MASCARA>

Ejemplo:

En el ejemplo del siguiente gráfico R1, R2 y R3 están cada uno emplazado en una vlan como si fuesen host, SWITCH tiene tres vlanes y cada puerto contra los routers anteriores estará en access. El puerto contra R5 está configurado en trunk. Y en el R5 tenemos configuradas subinterfaces que además están encapsulando el tráfico con 802.1q.


R1
interface FastEthernet0/0

ip address 192.168.1.1 255.255.255.0

ip route 0.0.0.0 0.0.0.0 192.168.1.5

R2
interface FastEthernet0/0

ip address 192.168.2.2 255.255.255.0

ip route 0.0.0.0 0.0.0.0 192.168.2.5

R3:
interface FastEthernet0/0

ip address 192.168.3.3 255.255.255.0

ip route 0.0.0.0 0.0.0.0 192.168.3.5

SWITCH:
Vlan 1

Vlan 2

Vlan 3

interface FastEthernet1/0

switchport access vlan 1

!

interface FastEthernet1/1

switchport access vlan 2

!

interface FastEthernet1/2

switchport access vlan 3

interface FastEthernet1/15

switchport mode trunk


R5
interface FastEthernet0/0

no ip address

!

interface FastEthernet0/0.1

encapsulation dot1Q 1

ip address 192.168.1.5 255.255.255.0

!

interface FastEthernet0/0.2

encapsulation dot1Q 2

ip address 192.168.2.5 255.255.255.0

!

interface FastEthernet0/0.3

encapsulation dot1Q 3

ip address 192.168.3.5 255.255.255.0

Haciendo ping desde R1 para probar todo:

R1#tracer 192.168.2.2

Type escape sequence to abort.

Tracing the route to 192.168.2.2

1 192.168.1.5 20 msec 60 msec 8 msec

2 192.168.2.2 32 msec * 24 msec

R1#ping 192.168.2.2

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 192.168.2.2, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 20/37/60 ms

R1#ping 192.168.3.3

Type escape sequence to abort.

Sending 5, 100-byte ICMP Echos to 192.168.3.3, timeout is 2 seconds:

!!!!!

Success rate is 100 percent (5/5), round-trip min/avg/max = 24/39/72 ms

Tabla de rutas en R5:
R5#show ip route

Codes: C - connected, S - static, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

E1 - OSPF external type 1, E2 - OSPF external type 2

i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2

ia - IS-IS inter area, * - candidate default, U - per-user static route

o - ODR, P - periodic downloaded static route

Gateway of last resort is not set

C 192.168.1.0/24 is directly connected, FastEthernet0/0.1

C 192.168.2.0/24 is directly connected, FastEthernet0/0.2

C 192.168.3.0/24 is directly connected, FastEthernet0/0.3

No hay comentarios:

Publicar un comentario