L3VPN – OSPF RIP

Read Concept Here

1Melanjutkan tulisan sebelumnya (lagi), pada tulisan ini akan membahas untuk menghubungkan antar CE menggukanan OSPF dan RIP.

First Step, Menghubungkan PE1 CE2 menggunakan OSPF

PE1(config)#int e0/2
PE1(config-if)#vrf forwarding B
PE1(config-if)#no shut
PE1(config-if)#ip addr 102.102.102.1 255.255.255.0
PE1(config-if)#router ospf 100 vrf B
PE1(config-router)#network 102.102.102.1 0.0.0.0 area 0
PE1(config-router)#network 11.11.11.2 0.0.0.0 area 0
CE2(config)#int e0/0
CE2(config-if)#no shut
CE2(config-if)#ip addr 102.102.102.2 255.255.255.0
CE2(config-if)#int lo0
CE2(config-if)#ip addr 22.22.22.22 255.255.255.255
CE2(config-if)#router ospf 100
CE2(config-router)#network 22.22.22.22 0.0.0.0 area 0
CE2(config-router)#network 102.102.102.2 0.0.0.0 area 0

Verifikasi

CE2#sh ip route
Codes: L – local, 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, H – NHRP, l – LISP
+ – replicated route, % – next hop overrideGateway of last resort is not set11.0.0.0/32 is subnetted, 1 subnets
O        11.11.11.2 [110/11] via 102.102.102.1, 00:00:27, Ethernet0/0
22.0.0.0/32 is subnetted, 1 subnets
C        22.22.22.22 is directly connected, Loopback0
102.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        102.102.102.0/24 is directly connected, Ethernet0/0
L        102.102.102.2/32 is directly connected, Ethernet0/0
CE2#ping 11.11.11.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 11.11.11.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 5/15/57 ms
CE2#

Second Step,Menghubungkan PE2 CE5 menggunakan RIP

PE2(config)#int e0/2
PE2(config-if)#no shut
PE2(config-if)#vrf forwarding B
PE2(config-if)#ip addr 35.35.35.3 255.255.255.0
PE2(config-if)#router rip
PE2(config-router)#address-family ipv4 vrf B
PE2(config-router-af)#version 2
PE2(config-router-af)#no auto-summ
PE2(config-router-af)#network 35.35.35.3
PE2(config-router-af)#network 33.33.33.2
CE5(config)#int lo0
CE5(config-if)#ip addr 55.55.55.55 255.255.255.255
CE5(config-if)#int e0/0
CE5(config-if)#ip addr 35.35.35.5 255.255.255.0
CE5(config-if)#router rip
CE5(config-router)#version 2
CE5(config-router)#no auto-summ
CE5(config-router)#network 35.35.35.5
CE5(config-router)#network 55.55.55.55

Verifikasi

CE5#sh ip route
Codes: L – local, 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, H – NHRP, l – LISP
+ – replicated route, % – next hop overrideGateway of last resort is not set33.0.0.0/32 is subnetted, 1 subnets
R        33.33.33.2 [120/1] via 35.35.35.3, 00:00:06, Ethernet0/0
35.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        35.35.35.0/24 is directly connected, Ethernet0/0
L        35.35.35.5/32 is directly connected, Ethernet0/0
55.0.0.0/32 is subnetted, 1 subnets
C        55.55.55.55 is directly connected, Loopback0
CE5#ping 33.33.33.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 33.33.33.2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 5/5/5 ms
CE5#

*terlihat routing PE2 terdapat di CE5 namun untuk routingan VRF sebelah belum dapat karena rutenya belum dibocorin (read: redistribute)

Third Step, Redistribute PE1 CE2 dan PE2 CE5. Buat ngebocorin masing2 rutenya

Redistribute PE1 CE2

PE1(config)#router bgp 100
PE1(config-router)#address-family ipv4 vrf B
PE1(config-router-af)#redistribute ospf 100 vrf B match internal external 1 external 2
PE1(config-router-af)#router ospf 100 vrf B
PE1(config-router)#redistribute bgp 100 subnet

Redistribute PE2 CE5

PE2(config)#router bgp 100
PE2(config-router)#address-family ipv4 vrf B
PE2(config-router-af)#redistribute rip metric 2
PE2(config)#router rip
PE2(config-router)#address-family ipv4 vrf B
PE2(config-router-af)#redistribute bgp 100 metric 2

Verifikasi

CE5#sh ip route
Codes: L – local, 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, H – NHRP, l – LISP
+ – replicated route, % – next hop overrideGateway of last resort is not set11.0.0.0/32 is subnetted, 1 subnets
R        11.11.11.2 [120/2] via 35.35.35.3, 00:00:06, Ethernet0/0
22.0.0.0/32 is subnetted, 1 subnets
R        22.22.22.22 [120/2] via 35.35.35.3, 00:00:06, Ethernet0/0
33.0.0.0/32 is subnetted, 1 subnets
R        33.33.33.2 [120/1] via 35.35.35.3, 00:00:06, Ethernet0/0
35.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        35.35.35.0/24 is directly connected, Ethernet0/0
L        35.35.35.5/32 is directly connected, Ethernet0/0
55.0.0.0/32 is subnetted, 1 subnets
C        55.55.55.55 is directly connected, Loopback0
102.0.0.0/24 is subnetted, 1 subnets
R        102.102.102.0 [120/2] via 35.35.35.3, 00:00:06, Ethernet0/0
CE5#ping 22.22.22.22
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 22.22.22.22, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/6/9 ms
CE5#

Pastikan CE5 dan CE2 dapat berkomunikasi satu sama lain.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.