Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

New Member

Redistribute static route into OSPF question

Hello

I'm doing Redistribute in GNS3, please download my lab first in attached file.

You  can see four routers, R1,R2,R3 running OSPF in vlan 10,20,30, can ping  each ip address between three routers, then I added R4 and R5 for  testing

redistribute static route. In R3, I have create default  route to R4 and R4 create default route to R3 and so on. In R2 also  create default route to R5 and R5

create default route to R2 and so on.

But still cannot ping between R4 and R5, please help.

Thanks

1 ACCEPTED SOLUTION

Accepted Solutions

Redistribute static route into OSPF question

Wilson,

You have a default route on R5 that points to 3 different gateways. You've advertised only one of those networks on R2 so R4 would know about it. Since you have 3 equal cost routes, the router will load balance and send a packet out of each one, so that's why you're seeing drops and different destination addresses because R3 doesn't know about the other two networks that are on R2/R5:

00:07:14: ICMP: echo reply sent, src 192.168.10.2, dst 172.17.228.2

00:07:14: ICMP: echo reply sent, src 192.168.10.2, dst 172.16.228.2

You'll need to advertise 172.17.228.0/24 and 10.10.228.0/24 on R2 as well and you're problem would be resolved:

R5#ping 192.168.10.2 rep 50

Type escape sequence to abort.

Sending 50, 100-byte ICMP Echos to 192.168.10.2, timeout is 2 seconds:

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Success rate is 100 percent (50/50), round-trip min/avg/max = 64/83/116 ms

R5#

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***
19 REPLIES
Hall of Fame Super Blue

Redistribute static route into OSPF question

I am having a problem opening your zip file. Can you try posting again or just post the individual files as attachements.

In general terms, is the problem that you are not seeing the redistributed routes ? If so then are you adding the "subnets" keyword ie.

router ospf

redistribute static subnets

If they are being redistributed then it is a case of looking at all the routing tables on each router. Remember you must account for the return path as well.

If the above doesn't help please post as attachments.

Jon

New Member

Redistribute static route into OSPF question

Hi Jon

This forum do not allow me add attached file in reply, any idea ?

Hall of Fame Super Blue

Re: Redistribute static route into OSPF question

it should do. When you click on reply (to my post) along the top of the box you type in there is a hyperlink for the "Use advanced editor". Click on that and then you should see at the bottom of the reply box an "Attach Files" link which should allow you to add the files to the post as attachments.

Jon

New Member

Re: Redistribute static route into OSPF question

I sent PM yo you that include the file link.

Hall of Fame Super Blue

Redistribute static route into OSPF question

Have no idea of what application i need to open a .net file.

Can you not post them as files following the instructions i gave above. The thing is even if you post the configs we may need further outputs like "sh ip route" etc. so it would be good if you could start attaching files to your posts.

Jon

New Member

Re: Redistribute static route into OSPF question

It open by GNS3 application.

Please see attahced file for all routers of sh ip route and the diagram.

Re: Redistribute static route into OSPF question

Wilson,

R1 and R2 doesn't see your routes for R4. Can you post the ospf config for all routers? If we can't figure it out from configs, I'll have to reconfigure your .net file to run on my box. You're running it in Windows and I run it on a mac with a different IOS image than what you're using. There will need to be quite a few mods before I can get it to work on my end.

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***
New Member

Re: Redistribute static route into OSPF question

R3:

router ospf 1

log-adjacency-changes

redistribute static subnets

network 10.0.0.0 0.0.0.255 area 0

!

router ospf 2

log-adjacency-changes

network 10.0.1.0 0.0.0.255 area 0

network 10.0.2.0 0.0.0.255 area 0

R1:

router ospf 1

log-adjacency-changes

network 10.0.0.0 0.0.0.255 area 0

network 192.168.0.0 0.0.0.255 area 0

!

router ospf 2

log-adjacency-changes

network 10.0.1.0 0.0.0.255 area 0

network 192.168.1.0 0.0.0.255 area 0

!

router ospf 3

log-adjacency-changes

network 10.0.2.0 0.0.0.255 area 0

network 192.168.2.0 0.0.0.255 area 0

R2:

router ospf 1

log-adjacency-changes

redistribute static subnets

network 192.168.0.0 0.0.0.255 area 0

!

router ospf 2

log-adjacency-changes

network 192.168.1.0 0.0.0.255 area 0

New Member

Re: Redistribute static route into OSPF question

This is testing only, so some vlan not apply on OSPF, thanks.

Re: Redistribute static route into OSPF question

Wilson,

Why are you using so many processes on each router? It's not necessary to achieve what you're wanting and it's complicating the matters. When you have two different processes on the router, you can form adjacencies on both ends of the router, but neither end knows about routes from the other without the middle router doing redistribution of the ospf process. I'm not sure if that's what is happening here, but it's my first guess. Can you try something for me? Try redistributing the ospf processes on R3 to see if this resolves the issue. If it doesn't, I'll lab yours up this afternoon:

Change this on R3:

R3:

router ospf 1

log-adjacency-changes

redistribute ospf 2 subnets

redistribute static subnets

network 10.0.0.0 0.0.0.255 area 0

!

router ospf 2

redistribute ospf 1 subnets

log-adjacency-changes

network 10.0.1.0 0.0.0.255 area 0

network 10.0.2.0 0.0.0.255 area 0

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***

Re: Redistribute static route into OSPF question

Wilson,

I modified the config to run in GNS. Redistribution doesn't resolve the issue, so let me play around with this lab and I'll get back with you.

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***

Re: Redistribute static route into OSPF question

Wilson,

I had some time to look at the lab this evening. The problem is two fold. You are redistributing statics on R3, but the only static that you have is the default route. This isn't treated as a true static, so you would need "default-information originate" on R3 in order to send it to R1 and pass it to the routers on the right.

The issue with that is that the way that you're wanting to do this, at least I'm assuming by the routes on R2 and R3, is that R4 and R5 will need to send their unknown routes to their respective upstream router. R4 would send anything it didn't know about to R3, but R3's default route is sent back to R4, and the same thing happens on the other side with R5 sending to R2 as a default route, but R2's static default route is pointing back to R5. This may be a little confusing.

In order to ping from R4 to R5, all of the routers in between will need to know about the routes on these routers. Let's use 192.168.10.0/24 on R4. R5 doesn't know about it, so when you try to ping it, it sends to R2. R2 doesn't know about it because it's not advertised, so it sends the traffic back to R5 which isn't what you want.

So, in order to fix it, you need to have all networks between all hosts advertised and known. For example, on R3, you can advertise for the three networks - 192.168.10.0/24 192.168.20.0/24 192.168.30.0/24 - and R1 and R2 will now know about them. When R5 sends traffic to 192.168.10.2 (R4), R2 can direct the traffic to R1 and then R3 and finally to R4. What happens if R4 receives a packet from 172.17.228.2? It will drop it if R2 isn't advertising for that network since it holds those subnets. R3 needs to know how to get back to R2's subnets in order for R4 to return the traffic since R4 is using R3 as it's default gateway. So you would also need to advertise the subnets from R2 into ospf so R3 knows how to get to them.

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***
New Member

Re: Redistribute static route into OSPF question

Do you mean I have to add static route on each router ? so they can reach each others.

New Member

Re: Redistribute static route into OSPF question

Hi John,

After done following steps, R5 can ping R4 192.168.10.0/24 VLan 10:

1. In R2, remove all static route to R5

2. In R2, add network 172.17.228.0 in OSPF 1

3. in R3, add network 192.168.10.0 in OSPF 1

After ping from R5 to R4, it only have 2 percent (see attached file)

Thanks

Re: Redistribute static route into OSPF question

On R4, run "debug ip icmp" and start your ping again from R5. Post the results....

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***
New Member

Re: Redistribute static route into OSPF question

Log from R4

R4#

00:07:14: ICMP: echo reply sent, src 192.168.10.2, dst 172.17.228.2

00:07:14: ICMP: echo reply sent, src 192.168.10.2, dst 172.16.228.2

00:07:14: ICMP: dst (192.168.10.2) host unreachable rcv from 192.168.30.1

R4#

00:07:16: ICMP: echo reply sent, src 192.168.10.2, dst 10.10.228.2

00:07:16: ICMP: dst (192.168.10.2) host unreachable rcv from 192.168.10.1

R4#

00:07:18: ICMP: echo reply sent, src 192.168.10.2, dst 172.17.228.2

00:07:18: ICMP: echo reply sent, src 192.168.10.2, dst 172.16.228.2

00:07:18: ICMP: dst (192.168.10.2) host unreachable rcv from 192.168.30.1

Ping from R5

R5#ping 192.168.10.2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.10.2, timeout is 2 seconds:
!..!.
Success rate is 40 percent (2/5), round-trip min/avg/max = 80/90/

Thanks

Redistribute static route into OSPF question

Wilson,

You have a default route on R5 that points to 3 different gateways. You've advertised only one of those networks on R2 so R4 would know about it. Since you have 3 equal cost routes, the router will load balance and send a packet out of each one, so that's why you're seeing drops and different destination addresses because R3 doesn't know about the other two networks that are on R2/R5:

00:07:14: ICMP: echo reply sent, src 192.168.10.2, dst 172.17.228.2

00:07:14: ICMP: echo reply sent, src 192.168.10.2, dst 172.16.228.2

You'll need to advertise 172.17.228.0/24 and 10.10.228.0/24 on R2 as well and you're problem would be resolved:

R5#ping 192.168.10.2 rep 50

Type escape sequence to abort.

Sending 50, 100-byte ICMP Echos to 192.168.10.2, timeout is 2 seconds:

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

Success rate is 100 percent (50/50), round-trip min/avg/max = 64/83/116 ms

R5#

HTH,
John

*** Please rate all useful posts ***

HTH, John *** Please rate all useful posts ***
New Member

Re: Redistribute static route into OSPF question

Hello

I have edited some settings, but still have some delay with ping, please take a look on attached GNS3 file.

Thanks

New Member

Re: Redistribute static route into OSPF question

No ping delay now, thanks !

363
Views
0
Helpful
19
Replies