cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1432
Views
20
Helpful
11
Replies

Dynamic Routing Not Working Correctly?

Tom101
Level 1
Level 1

Hello,

 

I'm studying for the CCNA, and trying to figure my head around dynamic routing.

 

The task is to set up 3x autonomous system that uses the protocols ospf and bgp to set up dynamic routing and to share ip routes. 

 

These are the steps i have taken so far. I have set up 3 bgp areas called 100, 200 and 300. 

 

On the routers inside each autonomous system i have used the commands below. I have added the label 'X' to represent a number of the ip addresses. To keep it simple all the subnet masks are /24. 

 

router ospf 1

redistribute bgp X

network 192.X.0.0 0.0.0.255 area 1

network 192.X.0.0 0.0.0.255 area 1

network X.X.0.0 0.0.0.255 area 1


On the outer routers I have set up the necessary OSPF network id, as well as used the commands below to set up the neighbour IP address, and to select the remote-as bgp autonomous area. 

 

router bgp x

neighbor x.x.x.x remote-as x

network x.0.0.0

redistribute ospf 1


I can get all the routers inside each area to ping each other, but some of the outer routers pings aren't working (not sure if they're meant to?) and the three pc also cannot receive any pings from each other - which tells me i have done something incorrect, i just cannot figure out what.

 

My question is, does it look like i'm doing anything wrong, and are OSFP and BGP suppose to work like that? 

 

To help everyone understand i have attached a photo of the network, as well as a Cisco 8.1.1 packet tracer file. If anyone could point me in the right direction that would be fantastic.

 

Thank you. 

 

 

 

 

2 Accepted Solutions

Accepted Solutions

Under ospf

Redistrubte bgp x subnet




Under bgp

Redistrubte-internal

 

Try both and do ping again

View solution in original post

Hello,

 

It looks like your subnets are not quite being advertised correctly. 

 

You have network 11.11.0.0 advertised instead of 11.11.11.0. This is the same for all your PC connected networks. 

 

Change the network statement from 11.11.0.0 0.0.0.255 area 1 to 11.11.11.0 0.0.0.255 area 0 (I say area 0 because that best practice when only a single area)

Remember 0 means exactly this number and 255 means I don't care about this number.

 

Also when redistributing into OSPF use the subnets keyword to not just get classful networks:

 

redistribute bgp 100 

 

Hope that helps.

 

-David

View solution in original post

11 Replies 11

Under ospf

Redistrubte bgp x subnet




Under bgp

Redistrubte-internal

 

Try both and do ping again

Thank you for your reply. I added both of the commands you've listed. Still getting request timed out when i ping them.

 

When doing tracert the ping doesn't seem to know where to go after it arrives at the default gateway - which is the interface it's connected to.

...

I retried this on a new packet tracer file, with correct wildcard masks and this fixed my problem too.  

Hello,

 

It looks like your subnets are not quite being advertised correctly. 

 

You have network 11.11.0.0 advertised instead of 11.11.11.0. This is the same for all your PC connected networks. 

 

Change the network statement from 11.11.0.0 0.0.0.255 area 1 to 11.11.11.0 0.0.0.255 area 0 (I say area 0 because that best practice when only a single area)

Remember 0 means exactly this number and 255 means I don't care about this number.

 

Also when redistributing into OSPF use the subnets keyword to not just get classful networks:

 

redistribute bgp 100 

 

Hope that helps.

 

-David

Perfect David, works like a charm. Thank you. 

Quick question, are all the routers suppose to be able to ping each other in a set up like this? All my routers are able to ping each other a part from a couple. (Router 6 to router 4 and 5). What could be the reason for that? 

They can not don’t have to. Depends on the design of the network. Usually the reason is they don’t know how to reach each other.

As in there is no route in the routing table. Start with one router and make sure the interfaces/subents you want reachable are advertised. Then go around to every other router and see if those subnets are in the routing table. If not you me shoot that connection/ neighborship. 
It’s usually a bit more involved than that if you have access lists and route filtering because of the many ways to suppress and manipulate routes but it looks like yours is a simple topology without all that.

show ip bgp
 
in R0

 
from there I will analysis all BGP routes 

Screenshot 2022-04-17 at 01.10.24.png

 

Picture attached. 

R0 don't know anything about AS300?
are R0 is iBGP with R2? if not then you have classic not full mesh iBGP 
meaning 
R0-R1-R2
R2 iBGP R1 
R1 iBGP R0

any prefix R1 receive from R2 never resend to R0 since BGP rule is full mesh between iBGP peer. 
so R0 never know R2 prefix 

how can I fix this issue?
config iBGP between R0 and R2 "same for each other AS"
be sure that R0 know how to reach R2. use static or dynamic routing.

Review Cisco Networking for a $25 gift card