cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1398
Views
0
Helpful
2
Replies

configure static route using next-hop + outgoing interface

mohammed hashim
Level 1
Level 1

hi,

something like: ip route 192.168.7.0 255.255.255.0 GigabitEthernet1 10.0.0.1

what is the use of it !?

also will it differ if it was like ip route 192.168.7.0 255.255.255.0 10.0.0.1 GigabitEthernet1 

thanks,

2 Replies 2

Robenneke
Level 1
Level 1

The article in the link that Robenneke gives is about the difference in a static route which specifies the next hop address or a static routes which specifies the outbound interface. But it does not discuss the situation in which a static route specifies both the outbound interface and the next hop address. And this is what the original poster is asking.

The original poster asks what is the use of it to specify both the next hop address and the outbound interface. Let me try to explain it in this way:

The article in the link that Robenneke gives provides a pretty good explanation of the advantage of specifying the next hop address if the outbound interface is an Ethernet type of interface. So in the example given by the original poster we need to specify the next hop of 10.0.0.1. But what if 10.0.0.1 is not a directly connected address. Then IOS will do a recursive lookup to find how to get to that address. Perhaps it turns out that 10.0.0.1 can be reached using Gig1 which supplies encryption of traffic going out that interface and that it is also reached using Serial2 which does not encrypt its traffic. If it is important that traffic to 192.168.7.0 be encrypted then it is important to specify that it use Gig1 and not Serial2. What is what we achieve when we specify both the outbound interface and the next hop address.

HTH

Rick

HTH

Rick
Review Cisco Networking for a $25 gift card