01-09-2014 05:12 AM - edited 03-04-2019 10:01 PM
Hello everyone,
ip route 0.0.0.0 0.0.0.0 10.1.1.1
ip route 0.0.0.0 0.0.0.0 10.1.1.2
ip route 0.0.0.0 0.0.0.0 10.1.1.3
ip route 0.0.0.0 0.0.0.0 10.1.1.4
ip route 0.0.0.0 0.0.0.0 10.1.1.5
ip route 0.0.0.0 0.0.0.0 10.1.1.6
I suppose, I can add up to 6 static routes for the same network for load traffic. Is it true?
Can I add a command to limit it up to 2 only?
I am not sure, but probably all next hops for these routes have to be reachable via the same physical interface.
R0------SW1-----R1
| |
R2 R3
I can't find any Cisco refference about both statements, could you help me? My questions related to both IOS: classical and IOS-XR. Thank you in advance.
--
Dmitry
Solved! Go to Solution.
01-09-2014 07:54 AM
Dmitry,
In version 12.4, I can get 16 routes in the table:
R1(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 1.1.1.17 to network 0.0.0.0
1.0.0.0/24 is subnetted, 1 subnets
C 1.1.1.0 is directly connected, Loopback1
S* 0.0.0.0/0 [1/0] via 1.1.1.17
[1/0] via 1.1.1.16
[1/0] via 1.1.1.15
[1/0] via 1.1.1.14
[1/0] via 1.1.1.13
[1/0] via 1.1.1.12
[1/0] via 1.1.1.11
[1/0] via 1.1.1.10
[1/0] via 1.1.1.9
[1/0] via 1.1.1.8
[1/0] via 1.1.1.7
[1/0] via 1.1.1.6
[1/0] via 1.1.1.5
[1/0] via 1.1.1.4
[1/0] via 1.1.1.3
[1/0] via 1.1.1.2
R1(config)#
The way to do only 2 at a time would be to set your two preferred routes that you would want, and then set the others with a higher AD so they
wouldn't get put into the routing table until one of your preferred routes failed.
To note, I can't tell you if this is the same in IOS-XR. I don't have access to that IOS, but normal IOS allows for the above.
HTH,
John
*** Please rate all useful posts ***
01-09-2014 08:14 AM
Dmitry
There should be no problem with using different next hop IPs or exit interfaces.
Jon
01-09-2014 07:54 AM
Dmitry,
In version 12.4, I can get 16 routes in the table:
R1(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 1.1.1.17 to network 0.0.0.0
1.0.0.0/24 is subnetted, 1 subnets
C 1.1.1.0 is directly connected, Loopback1
S* 0.0.0.0/0 [1/0] via 1.1.1.17
[1/0] via 1.1.1.16
[1/0] via 1.1.1.15
[1/0] via 1.1.1.14
[1/0] via 1.1.1.13
[1/0] via 1.1.1.12
[1/0] via 1.1.1.11
[1/0] via 1.1.1.10
[1/0] via 1.1.1.9
[1/0] via 1.1.1.8
[1/0] via 1.1.1.7
[1/0] via 1.1.1.6
[1/0] via 1.1.1.5
[1/0] via 1.1.1.4
[1/0] via 1.1.1.3
[1/0] via 1.1.1.2
R1(config)#
The way to do only 2 at a time would be to set your two preferred routes that you would want, and then set the others with a higher AD so they
wouldn't get put into the routing table until one of your preferred routes failed.
To note, I can't tell you if this is the same in IOS-XR. I don't have access to that IOS, but normal IOS allows for the above.
HTH,
John
*** Please rate all useful posts ***
01-09-2014 08:09 AM
hi John,
thank you very much! AD is not an option. I am trying to find something like "maximum-paths 10" under ospf/bgp/rip, but for static routing. Not clear can I use the destination-ip from different networks (via different interfaces)...
my question is not very practical, rather for better understanding. thanks!
--
Dmitry
01-09-2014 08:14 AM
Dmitry
There should be no problem with using different next hop IPs or exit interfaces.
Jon
01-09-2014 08:15 AM
It looks like you have that option with IOS-XR:
As far as IOS, I don't believe you're going to have any other option other than AD. Maximum paths is limited to a routing protocol.
HTH,
John
*** Please rate all useful posts ***
01-09-2014 09:31 PM
Hi John,
yes, I've seen this command before, but it limits the total amount of static routes into your routing table.
"maximum path (static): To change the maximum number of allowable static routes, use the maximum path command in static router configuration mode."
Anyway, you helped me a lot! Thank you very much!
--
Dmitry
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide