Helpp With a route statement

Answered Question
Jul 30th, 2009
User Badges:

Hello Everyone,


I need some help with a route statement. On a 2851 with a point to point connection to another 2851 I need a statement that will send all traffic that comes up from the Gigabit interface destined for subnet 10.0.5.0 out serial interface 0/0/0. The IP address on the other end of the point to point is 10.50.10.1



Thanks in advance! Al replies rated!

Correct Answer by John Blakley about 7 years 9 months ago

Actually, you would add in addition to if the 10.0.5.0 subnet is going to be staying.


Say you have serial0 and serial1:


s0: 10.50.10.2 --> s0: 10.50.10.1

s1: 192.168.2.1 --> s1: 192.168.2.2


The internal network is on G0: 172.15.15.0/24


S0 peers with another router on it's S0 interface with address of 10.50.10.1 and the internal subnet is 10.0.5.0.


S1 peers with a different router on it's S0 interface at 192.168.2.2 and an internal subnet of 172.15.15.0.


On your router with S0 and S1, you would just create two static routes to the two internal subnets on the other side of your links like:


ip route 10.0.5.0 255.255.255.0 10.50.10.1

ip route 172.15.15.0 255.255.255.0 192.168.2.2


The router is smart enough to know which interface to go out of. :) Both static routes can stay.


HTH,

John

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (3 ratings)
Loading.
Richard Burts Thu, 07/30/2009 - 07:17
User Badges:
  • Super Silver, 17500 points or more
  • Hall of Fame,

    Founding Member

  • Cisco Designated VIP,

    2017 LAN, WAN

Angel


If your requirement is to send traffic destined for subnet 10.0.5.0 over the serial link to next hop 10.50.10.1 then a simple static route will be sufficient. It would look something like this:

ip route 10.0.5.0 255.255.255.0 10.50.10.1


But if the requirement is to send traffic to 10.0.5.0 over the serial only if it comes from the Gigabit interface then you would need either to use VRF-lite or to use Policy Based Routing.


HTH


Rick

John Blakley Thu, 07/30/2009 - 07:17
User Badges:
  • Purple, 4500 points or more

If you're just wanting to use a static route, you could try:


ip route 10.0.5.0 10.50.10.1


You said that you wanted any traffic coming from the g0/0 interface to go there though. Is there anything special to this interface that you need to lock it down to being just that interface? If so, you may need a route-map. The above statement would allow any traffic destined for the 10.0.5.0 subnet to go to the 10.50.10.1 interface on the other side.



HTH,

John

angel-moon Thu, 07/30/2009 - 07:22
User Badges:

Thanks Guys. For now I think simple is best. I forgot to mention that there will be a second Serial interface on this router with different subnets that it needs to get to. I imagine that all I need to do is change the IP addresses on the statements provided correct?

Correct Answer
John Blakley Thu, 07/30/2009 - 07:39
User Badges:
  • Purple, 4500 points or more

Actually, you would add in addition to if the 10.0.5.0 subnet is going to be staying.


Say you have serial0 and serial1:


s0: 10.50.10.2 --> s0: 10.50.10.1

s1: 192.168.2.1 --> s1: 192.168.2.2


The internal network is on G0: 172.15.15.0/24


S0 peers with another router on it's S0 interface with address of 10.50.10.1 and the internal subnet is 10.0.5.0.


S1 peers with a different router on it's S0 interface at 192.168.2.2 and an internal subnet of 172.15.15.0.


On your router with S0 and S1, you would just create two static routes to the two internal subnets on the other side of your links like:


ip route 10.0.5.0 255.255.255.0 10.50.10.1

ip route 172.15.15.0 255.255.255.0 192.168.2.2


The router is smart enough to know which interface to go out of. :) Both static routes can stay.


HTH,

John

Actions

This Discussion