We configured r1 (only eth 1) r2 (eth0) and r3 (only eth0) with ospf and we configured R3 (eth1) and R4 (eth0 and eth1) with RIP and redistributed the connected routes lets take a look at our rip configuration and also a quick review on all of our route tables on all of our routers, we are not going to go through all of the details of the rip protocol we have a separate article for that
vyatta@r4# configure
vyatta@r4# set protocols rip interface eth0
vyatta@r4# set protocols rip interface eth1
vyatta@r4# set protocols rip redistribute connected
vyatta@r4# commit
vyatta@r4:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
R>* 10.10.10.0/24 [120/2] via 20.20.20.3, eth0, 00:08:38
C>* 20.20.20.0/24 is directly connected, eth0
C>* 60.60.60.0/24 is directly connected, eth1
C>* 127.4.4.0/24 is directly connected, lo
vyatta@r3:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
O 10.10.10.0/24 [110/10] is directly connected, eth0, 00:28:41
C>* 10.10.10.0/24 is directly connected, eth0
C>* 20.20.20.0/24 is directly connected, eth1
R>* 60.60.60.0/24 [120/2] via 20.20.20.4, eth1, 00:09:41
O>* 127.1.1.1/32 [110/20] via 10.10.10.1, eth0, 00:26:18
O>* 127.2.2.2/32 [110/20] via 10.10.10.2, eth0, 00:27:45
C>* 127.3.3.0/24 is directly connected, lo
vyatta@r2:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
O 10.10.10.0/24 [110/10] is directly connected, eth0, 00:28:44
C>* 10.10.10.0/24 is directly connected, eth0
O>* 127.1.1.1/32 [110/20] via 10.10.10.1, eth0, 00:26:33
C>* 127.2.2.0/24 is directly connected, lo
O>* 127.3.3.3/32 [110/20] via 10.10.10.3, eth0, 00:27:55
vyatta@r1:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
K>* 0.0.0.0/0 via 192.168.1.1, eth0
O 10.10.10.0/24 [110/10] is directly connected, eth1, 00:26:40
C>* 10.10.10.0/24 is directly connected, eth1
C>* 127.1.1.0/24 is directly connected, lo
O>* 127.2.2.2/32 [110/20] via 10.10.10.2, eth1, 00:26:40
O>* 127.3.3.3/32 [110/20] via 10.10.10.3, eth1, 00:26:40
C>* 192.168.1.0/24 is directly connected, eth0
Now lets where do we have connectivity From r1 to r2 and r3 (eth0) and in reverse we have, since we haven’t configured ospf on eth0 on R1 we can’t ping from anywhere to it, the only reason we added this interface is so that we could connect to our network for configuration changes through a Telnet/SSH client
vyatta@r3:~$ ping 10.10.10.1
PING 10.10.10.1 (10.10.10.1) 56(84) bytes of data.
64 bytes from 10.10.10.1: icmp_seq=1 ttl=64 time=4.54 ms
64 bytes from 10.10.10.1: icmp_seq=2 ttl=64 time=1.21 ms
64 bytes from 10.10.10.1: icmp_seq=3 ttl=64 time=1.12 ms
64 bytes from 10.10.10.1: icmp_seq=4 ttl=64 time=1.15 ms
64 bytes from 10.10.10.1: icmp_seq=5 ttl=64 time=0.928 ms
--- 10.10.10.1 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4002ms
rtt min/avg/max/mdev = 0.928/1.793/4.542/1.377 ms We also have connectivity from R3 to R4 (since we have RIP configured we can ping both interfaces on R4 from R3 and vice versa)
vyatta@r3:~$ ping 60.60.60.4
PING 60.60.60.4 (60.60.60.4) 56(84) bytes of data.
64 bytes from 60.60.60.4: icmp_seq=1 ttl=64 time=4.13 ms
64 bytes from 60.60.60.4: icmp_seq=2 ttl=64 time=0.934 ms
64 bytes from 60.60.60.4: icmp_seq=3 ttl=64 time=0.769 ms
64 bytes from 60.60.60.4: icmp_seq=4 ttl=64 time=1.17 ms
64 bytes from 60.60.60.4: icmp_seq=5 ttl=64 time=1.30 ms
--- 60.60.60.4 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4001ms
rtt min/avg/max/mdev = 0.769/1.663/4.133/1.249 m
but we yet don’t have connectivity between the autonomous systems (RIP network and the OSPF network) or vice versa so what we have to redistribute RIP routes generated in the rip network and deliver them to the ospf network so that peers on the ospf network would be aware of the rip network as well, in the first case we would redistribute rip routes into our ospf network on R3
vyatta@r3# set protocols ospf redistribute rip
Now let’s take a look at our routing tables on r1 r2 and r3 and also to check for connectivity between them. (RIP routes injected into the OSPF network have the red color in the routing tables)
vyatta@r1:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
K>* 0.0.0.0/0 via 192.168.1.1, eth0
O 10.10.10.0/24 [110/10] is directly connected, eth1, 00:37:12
C>* 10.10.10.0/24 is directly connected, eth1
O>* 60.60.60.0/24 [110/20] via 10.10.10.3, eth1, 00:01:46
C>* 127.1.1.0/24 is directly connected, lo
O>* 127.2.2.2/32 [110/20] via 10.10.10.2, eth1, 00:37:12
O>* 127.3.3.3/32 [110/20] via 10.10.10.3, eth1, 00:37:12
C>* 192.168.1.0/24 is directly connected, eth0
vyatta@r2:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
O 10.10.10.0/24 [110/10] is directly connected, eth0, 00:40:46
C>* 10.10.10.0/24 is directly connected, eth0
O>* 60.60.60.0/24 [110/20] via 10.10.10.3, eth0, 00:03:04
O>* 127.1.1.1/32 [110/20] via 10.10.10.1, eth0, 00:38:35
C>* 127.2.2.0/24 is directly connected, lo
O>* 127.3.3.3/32 [110/20] via 10.10.10.3, eth0, 00:39:57
Now that the rip routes have been injected in to the ospf network we would be able to ping the 60.60.60.0/24 network from the ospf network lets ping R4 eth1 (60.60.60.4) from R2:
vyatta@r2:~$ ping 60.60.60.4
PING 60.60.60.4 (60.60.60.4) 56(84) bytes of data.
64 bytes from 60.60.60.4: icmp_seq=1 ttl=63 time=13.4 ms
64 bytes from 60.60.60.4: icmp_seq=2 ttl=63 time=2.08 ms
64 bytes from 60.60.60.4: icmp_seq=3 ttl=63 time=2.36 ms
64 bytes from 60.60.60.4: icmp_seq=4 ttl=63 time=2.27 ms
64 bytes from 60.60.60.4: icmp_seq=5 ttl=63 time=2.31 ms
--- 60.60.60.4 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4009ms
rtt min/avg/max/mdev = 2.089/4.490/13.411/4.461 ms
so we have connectivity from R1 to the 60.60.60.0/24 network (same goes for R1), now to get a better view try running a ping command to the 20.20.20.0/24 network see if you succeed(following the configurations we made to the network you shouldn’t get a reply), the question might come up is that : how come we have connectivity to the 60.60.60.0/24 and we are actually passing the 20.20.20.0/24 network but we cannot ping to that network? Well we don’t have any routes available to us guiding us to the 20.20.20.0/24 network in the OSPF network so we have to redistribute connected routes from the rip network into ospf as well, let’s do that see what comes up:
Let’s see if we could ping the 20.20.20.0/24 network from r1 or r2 vyatta@r2:~$ ping 20.20.20.4 PING 20.20.20.4 (20.20.20.4) 56(84) bytes of data. 64 bytes from 20.20.20.4: icmp_seq=1 ttl=63 time=3.43 ms --- 20.20.20.4 ping statistics --- 1 packets transmitted, 1 received, 0% packet loss, time 4005ms rtt min/avg/max/mdev = 2.175/2.496/3.432/0.476 ms
Let’s see the changes made based upon our configurations in the route tables of r1, r2 and r3:
vyatta@r2:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
O 10.10.10.0/24 [110/10] is directly connected, eth0, 00:46:54
C>* 10.10.10.0/24 is directly connected, eth0
O>* 20.20.20.0/24 [110/20] via 10.10.10.3, eth0, 00:01:10
O>* 60.60.60.0/24 [110/20] via 10.10.10.3, eth0, 00:09:12
O>* 127.1.1.1/32 [110/20] via 10.10.10.1, eth0, 00:44:43
C>* 127.2.2.0/24 is directly connected, lo
O>* 127.3.3.3/32 [110/20] via 10.10.10.3, eth0, 00:46:05
vyatta@r3:~$ show ip route NOTHING CHANGED
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
O 10.10.10.0/24 [110/10] is directly connected, eth0, 00:47:41
C>* 10.10.10.0/24 is directly connected, eth0
C>* 20.20.20.0/24 is directly connected, eth1
R>* 60.60.60.0/24 [120/2] via 20.20.20.4, eth1, 00:28:41
O>* 127.1.1.1/32 [110/20] via 10.10.10.1, eth0, 00:45:18
O>* 127.2.2.2/32 [110/20] via 10.10.10.2, eth0, 00:46:45
C>* 127.3.3.0/24 is directly connected, lo
vyatta@r1:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
K>* 0.0.0.0/0 via 192.168.1.1, eth0
O 10.10.10.0/24 [110/10] is directly connected, eth1, 00:45:44
C>* 10.10.10.0/24 is directly connected, eth1
O>* 20.20.20.0/24 [110/20] via 10.10.10.3, eth1, 00:02:15
O>* 60.60.60.0/24 [110/20] via 10.10.10.3, eth1, 00:10:18
C>* 127.1.1.0/24 is directly connected, lo
O>* 127.2.2.2/32 [110/20] via 10.10.10.2, eth1, 00:45:44
O>* 127.3.3.3/32 [110/20] via 10.10.10.3, eth1, 00:45:44
C>* 192.168.1.0/24 is directly connected, eth0 Now let’s see if we are able to ping from the rip network into the ospf network vyatta@r4:~$ ping 10.10.10.1 PING 10.10.10.1 (10.10.10.1) 56(84) bytes of data. 64 bytes from 10.10.10.1: icmp_seq=1 ttl=63 time=3.56 ms 64 bytes from 10.10.10.1: icmp_seq=2 ttl=63 time=2.54 ms 64 bytes from 10.10.10.1: icmp_seq=3 ttl=63 time=2.08 ms 64 bytes from 10.10.10.1: icmp_seq=4 ttl=63 time=2.10 ms --- 10.10.10.1 ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 3000ms rtt min/avg/max/mdev = 2.083/2.575/3.562/0.600 ms
Well yes we have connectivity , Let’s take a look at the route table on R4 to see the route we choose to reach the ospf network
vyatta@r4:~$ show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
I - ISIS, B - BGP, > - selected route, * - FIB route
R>* 10.10.10.0/24 [120/2] via 20.20.20.3, eth0, 00:31:21
C>* 20.20.20.0/24 is directly connected, eth0
C>* 60.60.60.0/24 is directly connected, eth1
C>* 127.4.4.0/24 is directly connected, lo
Well as you see we choose the rip route to ping the ospf network Let’s take a look at some changes in our OSPF network
vyatta@r3:~$ show ip ospf database
OSPF Router with ID (127.3.3.3)
Router Link States (Area 0.0.0.0)
Link ID ADV Router Age Seq# CkSum Link count
127.1.1.1 127.1.1.1 1230 0x80000006 0xec76 2
127.2.2.2 127.2.2.2 1234 0x80000005 0xed6c 2
127.3.3.3 127.3.3.3 899 0x80000008 0xec5e 2
Net Link States (Area 0.0.0.0)
Link ID ADV Router Age Seq# CkSum
10.10.10.3 127.3.3.3 1233 0x80000003 0xb564
AS External Link States
Link ID ADV Router Age Seq# CkSum Route
20.20.20.0 127.3.3.3 415 0x80000001 0x1edb E2 20.20.20.0/24 [0x0]
60.60.60.0 127.3.3.3 901 0x80000001 0x7809 E2 60.60.60.0/24 [0x0]
We’ve got AS external routes injected by the autonomous system border router into the ospf network, since this database is unique throughout the ospf network we are able to ping any interface in the rip network from the ospf network.
vyatta@r3:~$ show ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface RXmtL RqstL DBsmL
127.1.1.1 1 Full/DROther 38.071s 10.10.10.1 eth0:10.10.10.3 0 0 0
127.2.2.2 1 Full/Backup 38.384s 10.10.10.2 eth0:10.10.10.3 0 0 0
You could also check the ip ospf command on R3 just to view the state of the router which would state that this router is acting as an ASBR.
|