routing path

Unanswered Question
Mar 27th, 2008

i have packets destined to IP addresses

172.16.1.1,172.16.4.3,

i want to know which route this router would match

sh ip route shows

Gateway of last resort is not set

R 172.16.1.1/32

R 172.16.1.0/24

R 172.16.0.0/22

R 172.16.0.0/22

R 0.0.0.0/0

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Loading.
Jon Marshall Thu, 03/27/2008 - 21:53

Mahesh

Packets destined to 172.16.1.1 will use the 172.16.1.1/32 host route in the routing table.

You have 2 entries in the routing table that are the same ie.

172.16.0.0/22 - is this intended ?

Anyway

172.16.0.0/22 = 172.16.0.0 255.255.252.0

this covers 172.16.0.0 -> 172.16.3.255.

So packets destined to 172.16.4.3 will use the default route ie. 0.0.0.0

HTH

Jon

mahesh18 Thu, 03/27/2008 - 21:59

sorry for 1 mistake

R 172.16.0.0 /22 is actually

R 172.16.0.0/16

Can u explain we how u figure that out?

Thanks

Goutam Sanyal Thu, 03/27/2008 - 23:01

Mahesh,

R 172.16.0.0/16 is representing the routing protocol RIP, with the advertise network 172.16.0.0 and subnet musk 255.255.0.0

With more details, where the Host address ranges are 172.16.0.1 - 172.16.255.254. The Subnet ID 172.16.0.0 and the Broadcast 172.16.255.255, where the Max Subnet is 1 only with the host per subnet 64534.

Please rate if I am informative.

Thanks

Goutam

Jon Marshall Fri, 03/28/2008 - 01:49

Mahesh

Okay, then the packet 172.16.4.3 would use the 172.16.0.0/16 route. Goutam has explained the range of addressing that 172.16.0.0/16 covers.

Is there anything else you want clarification on ?

Jon

grichardson661 Fri, 03/28/2008 - 04:34

Correct me if i'm wrong but 172.16.4.3 doesn't match any of the routes in the routing table apart from the default route 0.0.0.0/0.

To my knowlege if a packets destination IP does not match a route in the routing table then the packet is disagarded unless a default route is configured. In your case it is 0.0.0.0/0. The default route will be used to forward packets if destination IP does not match a specific route.

Jon Marshall Fri, 03/28/2008 - 04:37

Have a look at the second post from the OP. There was a typo in the original post

ie.

172.16.0.0/22

172.16.0.0/22

one of these should have read

172.16.0.0/16

in which case 172.16.4.3 would use this route.

Jon

Actions

This Discussion