Next thing i looked at today was an overview of routing loops
why routing loops occur
-------------------------
-redistribution causes a loss of end to end route calculation + loop prevention
- e.g dual not compatiable with spf
- effectively when you redsitribute you are breaking the inbuilt loop prevention of
these protocols
looping cannot occur with single redistribution
- internal routing process prevents this like a single redistribution will not start incorrectly redistributing back into another protocol a protocol etc
it will only occur if there is multiple redistribution points
- wrong is selected this can happen due to
wrong path has a lower metric than the correct path (same protocl)
or
wrong path has lower AD than the correct path (Different protocols)
When we are doing redistributing we should visually map out the redistribution to predict what is happening so we predict loops before they happen
there are cli tools
we can do connectivity test with tclsh
and we can see looping
with debug ip route ( you will see routes been added then deleted)
ip route profile ( you will see unexpected high number of topology changes)
traceroute (see loop in path)
How to prevent
---------------
This depends why the looping occured
in the case of metric based loops
- they can be easily fixed by route filtering the particular route that is incorrect using acl,prefix-list,tag filtering,ad
in the case of admin distance based loops
- the only real way to fix this is to change the admin distance
EIGRP ROUTING LOOPS
--------------------
EIGRP can having routing loops and issue with route feedback causing routes not to be advertised when there is multiple ABR it is possible that some reachability is lost in eigrp network as the high admin distance of external eigrp (170) and the fact that in the eigrp protocol it will not advertise a route that is not made to the routing table even if it is in its topology database
you can see potential issue in eigrp with the following commands
sh ip eigrp - you will see the fd is inaccessible ths means you are learning the route via eigrp but something has lower admin distance stoping going into the routing table
or
sh ip eigrp top "ip"
you will the feasible distance is very large 4294967295 (infinite metric)
the composite metric will be a typical value like 2195456. This also means you are
learning the route from another source with lower admin distance
if you do a sh ip route "ip" it will give you the protocol that has been selected from the routing tale
to get around admin distance related issue we will need to change the admin distance
with eigrp it is NOT possible to change on prefix basis external eigrp routes admin distance you can change internal
in ospf rip bgp it is possible to change on prefix basis all routes admin distance
to change the admin distance for eigrp use the command
distance eigrp 90 109
where 90 is the admin distance for internal and 109 is the admin distance for external
LAB
----
OK for the lab i have setup the following topology we will start by redistributing ospf into eigrp on r1 it is worth rembering this is partial mesh r1 connect to r3
and r3 connects to r2
r1
--
r1(config-router)#router eigrp 1
r1(config-router)#redistribute ospf 1 metric 100 100 100 100 100
r1(config-router)#
r1#
*Mar 1 02:02:47.175: %SYS-5-CONFIG_I: Configured from console by console
r1#sh ip eigrp top
IP-EIGRP Topology Table for AS(1)/ID(10.229.254.1)
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
r - reply Status, s - sia Status
P 44.44.44.44/32, 1 successors, FD is 25625600
via Redistributed (25625600/0)
P 11.11.11.11/32, 1 successors, FD is 25625600
via Redistributed (25625600/0)
P 22.22.22.22/32, 1 successors, FD is 25625600
via Redistributed (25625600/0)
P 1.1.1.1/32, 1 successors, FD is 128256
via Connected, Loopback0
P 2.2.2.2/32, 1 successors, FD is 21152000
via 10.229.254.3 (21152000/20640000), Serial0/0
P 3.3.3.3/32, 1 successors, FD is 2297856
via 10.229.254.3 (2297856/128256), Serial0/0
P 1.0.0.0/8, 1 successors, FD is 128256
via Summary (128256/0), Null0
P 10.0.0.0/8, 1 successors, FD is 2169856
via Summary (2169856/0), Null0
P 10.228.254.0/24, 1 successors, FD is 2172416
via 10.229.254.3 (2172416/28160), Serial0/0
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
r - reply Status, s - sia Status
P 10.229.254.0/24, 1 successors, FD is 2169856
via Connected, Serial0/0
P 33.33.33.0/24, 1 successors, FD is 2300416
via 10.229.254.3 (2300416/156160), Serial0/0
P 192.168.1.0/24, 1 successors, FD is 25625600
via Redistributed (25625600/0)
P 192.168.2.0/24, 1 successors, FD is 25625600
via Redistributed (25625600/0)
P 192.168.3.0/24, 1 successors, FD is 25625600
via Redistributed (25625600/0)
P 192.168.5.0/24, 1 successors, FD is 25625600
via Redistributed (25625600/0)
r1#
r1#
we can see a whole bunch of redistributed routes lets check downstream r2 routing table
r2
---
r2#sh 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
D 1.0.0.0/8 [90/21152000] via 10.229.254.3, 00:06:11, Serial0/0
2.0.0.0/32 is subnetted, 1 subnets
C 2.2.2.2 is directly connected, Loopback0
33.0.0.0/24 is subnetted, 1 subnets
D 33.33.33.0 [90/2300416] via 10.229.254.3, 00:06:11, Serial0/0
3.0.0.0/32 is subnetted, 1 subnets
D 3.3.3.3 [90/2297856] via 10.229.254.3, 00:06:11, Serial0/0
10.0.0.0/24 is subnetted, 2 subnets
D 10.228.254.0 [90/2172416] via 10.229.254.3, 00:06:11, Serial0/0
C 10.229.254.0 is directly connected, Serial0/0
r2#
no sign of the redistributed routes
r2#sh ip route 22.22.22.22
% Network not in table
r2#sh ip eigrp top
IP-EIGRP Topology Table for AS(1)/ID(2.2.2.2)
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
r - reply Status, s - sia Status
P 3.3.3.3/32, 1 successors, FD is 2297856
via 10.229.254.3 (2297856/128256), Serial0/0
P 2.2.2.2/32, 1 successors, FD is 128256
via Connected, Loopback0
P 1.0.0.0/8, 1 successors, FD is 21152000
via 10.229.254.3 (21152000/20640000), Serial0/0
P 10.228.254.0/24, 1 successors, FD is 2172416
via 10.229.254.3 (2172416/28160), Serial0/0
P 10.229.254.0/24, 1 successors, FD is 2169856
via Connected, Serial0/0
P 33.33.33.0/24, 1 successors, FD is 2300416
via 10.229.254.3 (2300416/156160), Serial0/0
r2#
ok lets look at the issue
r3
---
r3#sh ip eigrp top
IP-EIGRP Topology Table for AS(1)/ID(3.3.3.3)
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
r - reply Status, s - sia Status
P 44.44.44.44/32, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
P 11.11.11.11/32, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
P 22.22.22.22/32, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
P 2.2.2.2/32, 1 successors, FD is 20640000
via 10.229.254.2 (20640000/128256), Serial1/0
P 3.3.3.3/32, 1 successors, FD is 128256
via Connected, Loopback0
P 1.0.0.0/8, 1 successors, FD is 20640000
via 10.229.254.1 (20640000/128256), Serial1/0
P 10.228.254.0/24, 1 successors, FD is 28160
via Connected, FastEthernet0/1
P 10.229.254.0/24, 1 successors, FD is 20512000
via Connected, Serial1/0
P 33.33.33.0/24, 1 successors, FD is 156160
via 10.228.254.1 (156160/128256), FastEthernet0/1
Codes: P - Passive, A - Active, U - Update, Q - Query, R - Reply,
r - reply Status, s - sia Status
P 192.168.1.0/24, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
P 192.168.2.0/24, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
P 192.168.3.0/24, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
P 192.168.5.0/24, 0 successors, FD is Inaccessible
via 10.229.254.1 (26137600/25625600), Serial1/0
r3#
notice we have a whole bunch of FD inaccessible a sign that it is learning the routes else where
r3#sh ip eigrp top 22.22.22.22 255.255.255.255
IP-EIGRP (AS 1): Topology entry for 22.22.22.22/32
State is Passive, Query origin flag is 1, 0 Successor(s), FD is 4294967295
Routing Descriptor Blocks:
10.229.254.1 (Serial1/0), from 10.229.254.1, Send flag is 0x0
Composite metric is (26137600/25625600), Route is External
Vector metric:
Minimum bandwidth is 100 Kbit
Total delay is 21000 microseconds
Reliability is 100/255
Load is 100/255
Minimum MTU is 100
Hop count is 1
External data:
Originating router is 10.229.254.1
AS number of route is 1
External protocol is OSPF, external metric is 3
Administrator tag is 0 (0x00000000)
r3#
the composite metric is 26137600 but the feasible distance is infinite (4294967295)
again another sign that this is been learnt else where
r3#sh ip route 22.22.22.22
Routing entry for 22.22.22.22/32
Known via "ospf 1", distance 110, metric 3, type intra area
Last update from 192.168.1.1 on FastEthernet0/0, 00:17:17 ago
Routing Descriptor Blocks:
* 192.168.1.1, from 22.22.22.22, 00:17:17 ago, via FastEthernet0/0
Route metric is 3, traffic share count is 1
we are learning via ospf as it has a admin distance of 110 vs the eigrp admin distance of 170 the ospf route is selected as it is in the routing table as ospf this is then not advertised down to r2 or s3
breaking reachability of the redistribution to repair this we could on
r3
---
so on r3 we could do the following
r3(config-router)#router eigrp 1
r3(config-router)#distance eigrp 90 109
r3(config-router)#
this makes eigrp distance of 90 for internal and 109 for external so the external should be preferred over ospf which is admin distance of 110
r3#sh 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
D 1.0.0.0/8 [90/20640000] via 10.229.254.1, 00:00:22, Serial1/0
2.0.0.0/32 is subnetted, 1 subnets
D 2.2.2.2 [90/20640000] via 10.229.254.2, 00:00:20, Serial1/0
33.0.0.0/24 is subnetted, 1 subnets
D 33.33.33.0 [90/156160] via 10.228.254.1, 00:00:51, FastEthernet0/1
3.0.0.0/32 is subnetted, 1 subnets
C 3.3.3.3 is directly connected, Loopback0
22.0.0.0/32 is subnetted, 1 subnets
D EX 22.22.22.22 [109/26137600] via 10.229.254.1, 00:00:22, Serial1/0
D EX 192.168.5.0/24 [109/26137600] via 10.229.254.1, 00:00:23, Serial1/0
10.0.0.0/24 is subnetted, 2 subnets
C 10.228.254.0 is directly connected, FastEthernet0/1
C 10.229.254.0 is directly connected, Serial1/0
11.0.0.0/32 is subnetted, 1 subnets
D EX 11.11.11.11 [109/26137600] via 10.229.254.1, 00:00:25, Serial1/0
C 192.168.1.0/24 is directly connected, FastEthernet0/0
D EX 192.168.2.0/24 [109/26137600] via 10.229.254.1, 00:00:25, Serial1/0
44.0.0.0/32 is subnetted, 1 subnets
D EX 44.44.44.44 [109/26137600] via 10.229.254.1, 00:00:25, Serial1/0
D EX 192.168.3.0/24 [109/26137600] via 10.229.254.1, 00:00:25, Serial1/0
r3#
now the routing table is using the eigrp routes over the ospf routes these should now be advertised to r2 and s3
r2(config)#do sh 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
D 1.0.0.0/8 [90/21152000] via 10.229.254.3, 00:01:30, Serial0/0
2.0.0.0/32 is subnetted, 1 subnets
C 2.2.2.2 is directly connected, Loopback0
33.0.0.0/24 is subnetted, 1 subnets
D 33.33.33.0 [90/2300416] via 10.229.254.3, 00:01:30, Serial0/0
3.0.0.0/32 is subnetted, 1 subnets
D 3.3.3.3 [90/2297856] via 10.229.254.3, 00:01:30, Serial0/0
22.0.0.0/32 is subnetted, 1 subnets
D EX 22.22.22.22 [170/26649600] via 10.229.254.3, 00:01:30, Serial0/0
D EX 192.168.5.0/24 [170/26649600] via 10.229.254.3, 00:01:32, Serial0/0
10.0.0.0/24 is subnetted, 2 subnets
D 10.228.254.0 [90/2172416] via 10.229.254.3, 00:01:31, Serial0/0
C 10.229.254.0 is directly connected, Serial0/0
11.0.0.0/32 is subnetted, 1 subnets
D EX 11.11.11.11 [170/26649600] via 10.229.254.3, 00:01:32, Serial0/0
D EX 192.168.2.0/24 [170/26649600] via 10.229.254.3, 00:01:32, Serial0/0
44.0.0.0/32 is subnetted, 1 subnets
D EX 44.44.44.44 [170/26649600] via 10.229.254.3, 00:01:32, Serial0/0
D EX 192.168.3.0/24 [170/26649600] via 10.229.254.3, 00:01:32, Serial0/0
r2(config)#
we now see the external routes via the redistution. Notice that we changed the admin distance on r3 to 109 but this admin distance is not what is on r2. Admin distance is locally signifcant the routing table of r3 has the D EX routes as 109 while r2 has them as 170
if you notice on r2 have reachabilty to all the networks in the ospf domain apart from r3 connected interface as r3 connected interface is running ospf it is not going to advertise to r2
So what happens is
R1 is learning 192.168.1.0 from ospf and it is redistributed into eigrp
r1#sh ip route 192.168.1.0
Routing entry for 192.168.1.0/24
Known via "ospf 1", distance 110, metric 2, type intra area
Redistributing via eigrp 1
Advertised by eigrp 1 metric 100 100 100 100 100
Last update from 192.168.3.11 on FastEthernet0/0, 00:30:24 ago
Routing Descriptor Blocks:
* 192.168.3.11, from 11.11.11.11, 00:30:24 ago, via FastEthernet0/0
Route metric is 2, traffic share count is 1
r1#sh ip eigrp top 192.168.1.0
IP-EIGRP (AS 1): Topology entry for 192.168.1.0/24
State is Passive, Query origin flag is 1, 1 Successor(s), FD is 25625600
Routing Descriptor Blocks:
192.168.3.11, from Redistributed, Send flag is 0x0
Composite metric is (25625600/0), Route is External
Vector metric:
Minimum bandwidth is 100 Kbit
Total delay is 1000 microseconds
Reliability is 100/255
Load is 100/255
Minimum MTU is 100
Hop count is 0
External data:
Originating router is 10.229.254.1 (this system)
AS number of route is 1
External protocol is OSPF, external metric is 2
Administrator tag is 0 (0x00000000)
r1#
this will be advertised to r3
r3
--
r3#sh ip eigrp top 192.168.1.0/24
IP-EIGRP (AS 1): Topology entry for 192.168.1.0/24
State is Passive, Query origin flag is 1, 0 Successor(s), FD is 4294967295
Routing Descriptor Blocks:
10.229.254.1 (Serial1/0), from 10.229.254.1, Send flag is 0x0
Composite metric is (26137600/25625600), Route is External
Vector metric:
Minimum bandwidth is 100 Kbit
Total delay is 21000 microseconds
Reliability is 100/255
Load is 100/255
Minimum MTU is 100
Hop count is 1
External data:
Originating router is 10.229.254.1
AS number of route is 1
External protocol is OSPF, external metric is 2
Administrator tag is 0 (0x00000000)
r3#
r3 recieves it but it is inaccessible via eigrp so it is been learnt by someother better admin distance
it is connected with a distance if 0
r3#sh ip route 192.168.1.0
Routing entry for 192.168.1.0/24
Known via "connected", distance 0, metric 0 (connected, via interface)
Routing Descriptor Blocks:
* directly connected, via FastEthernet0/0
Route metric is 0, traffic share count is 1
r3
this interface is put in to the routing table as of the lower admin distance
so is not advertised in eigrp as the connected interface is running ospf
r3#sh ip ospf int
FastEthernet0/0 is up, line protocol is up
Internet Address 192.168.1.3/24, Area 0
Process ID 1, Router ID 3.3.3.3, Network Type POINT_TO_POINT, Cost: 1
Transmit Delay is 1 sec, State POINT_TO_POINT,
Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
oob-resync timeout 40
Hello due in 00:00:02
Supports Link-local Signaling (LLS)
Index 1/1, flood queue length 0
Next 0x0(0)/0x0(0)
Last flood scan length is 1, maximum is 5
Last flood scan time is 0 msec, maximum is 4 msec
Neighbor Count is 1, Adjacent neighbor count is 1
Adjacent with neighbor 11.11.11.11
Suppress hello for 0 neighbor(s)
r3#
we could do redistribute connected we can not change the admin distance of connected route.
so on r3
-----------
r3(config)#router eigrp 1
r3(config-router)#redistribute connec
r3(config-router)#ex
now it is learnt on r2
-----------------------
r2#sh ip route 192.168.1.0
Routing entry for 192.168.1.0/24
Known via "eigrp 1", distance 170, metric 2172416, type external
Redistributing via eigrp 1
Last update from 10.229.254.3 on Serial0/0, 00:00:35 ago
Routing Descriptor Blocks:
* 10.229.254.3, from 10.229.254.3, 00:00:35 ago, via Serial0/0
Route metric is 2172416, traffic share count is 1
Total delay is 20100 microseconds, minimum bandwidth is 1544 Kbit
Reliability 255/255, minimum MTU 1500 bytes
Loading 1/255, Hops 1
R3
--
we could alternatively do a network command on r3 under eigrp 192.168.1.0
r3(config)#router eigrp 1
r3(config-router)#no redistribute connected
config)#router eigrp 1
r3(config-router)#network 192.168.1.0 0.0.0.255
r3(config-router)#exit
r3(r3#sh ip ospf int brief
Interface PID Area IP Address/Mask Cost State Nbrs F/C
Fa0/0 1 0 192.168.1.3/24 1 P2P 1/1
r3#sh ip eigrp int
IP-EIGRP interfaces for process 1
Xmit Queue Mean Pacing Time Multicast Pending
Interface Peers Un/Reliable SRTT Un/Reliable Flow Timer Routes
Lo0 0 0/0 0 0/10 0 0
Se1/0 2 0/0 74 5/190 708 0
Fa0/1 1 0/0 3 0/10 50 0
Fa0/0 0 0/0 0 0/10 0 0
r3#
so fa0/0 is running both ospf and eigrp
r2#sh ip route 192.168.1.0
Routing entry for 192.168.1.0/24
Known via "eigrp 1", distance 90, metric 2172416, type internal
Redistributing via eigrp 1
Last update from 10.229.254.3 on Serial0/0, 00:03:38 ago
Routing Descriptor Blocks:
* 10.229.254.3, from 10.229.254.3, 00:03:38 ago, via Serial0/0
Route metric is 2172416, traffic share count is 1
Total delay is 20100 microseconds, minimum bandwidth is 1544 Kbit
Reliability 255/255, minimum MTU 1500 bytes
Loading 1/255, Hops 1
r2#
the difference being it is now learnt by internal eigrp rather than external eigrp
the above types of problems would not happen in ospf as ospf sends all routes in it topology database in area
it is not down to what is in the routing table
No comments:
Post a Comment