OSPF.redistribute subnets

Unanswered Question
Feb 21st, 2009

Text from Book

------------

Parameter subnets specifies that subnetted routes should be redistributed also. Only routes that are not subnetted are redistributed if the subnets keyword is not specifed.

------------------------



Can any body explain me the phrase subbnetted routes in redistribution?

What does it mean? VSLM?

But OSPF by default VLSM protocol?


Maybe something like network 10.1.1.0 0.0.0.255 ??


Can you give me the example and explain my confused in this part?

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
Loading.
marikakis Sat, 02/21/2009 - 16:48

Please have a look at the ospf design guide that includes relevant information and an example:

http://www.cisco.com/en/US/tech/tk365/technologies_white_paper09186a0080094e9e.shtml#t32

"Note that the only external route that has appeared is 128.213.0.0, because we did not use the subnet keyword. Remember that if the subnet keyword is not used, only routes that are not subnetted will be redistributed. In our case 16.16.16.0 is a class A route that is subnetted and it did not get redistributed."


Note also that the subnets keyword applies to redistribution into OSPF. In the example in the guide above static routes are redistributed into OSPF and subnets keyword has to do with the mask of the static routes. In this example, if static has a "classic" A, B, C class mask it will get into OSPF. If it has any other mask, it won't.


This behavior doesn't have to do with the network command you use to enable OSPF into particular interfaces. The subnets used in the interfaces where OSPF is actually running will be advertised with their corresponding masks as expected (in general).

Joseph W. Doherty Sun, 02/22/2009 - 05:29

If I remember correctly, although OSPF is classless itself, (Cisco) redistribution into OSPF w/o the subnets parameter seems to assume classful networks.


For instance, under classful rules, 10.x.x.x is class A network (or /8 VLSM). 10.1.1.0/24, under classful rules is a subnet of the 10.x.x.x class A address. To have (Cisco) redistribute 10.1.1.0/24 into OSPF requires the subnets keyword. To have (Cisco) redistribute 10.0.0.0/8 into OSPF would not.


Usually when working with (Cisco) OSPF, you'll want to use the subnets keyword when doing redistribution into OSPF.


[edit]

If you wanted to redistribute 192.168.1.0/24 into OSPF, since, under class rules, it's a class C address, you wouldn't need the subnets parameter. However, 192.168.1.0/25, a class C subnet, you would need subnets parameter.


Not sure what happens with "supernets". E.g., 192.168.0.0/23. I believe subnets parameter would inject properly, but don't know what happens if subnets parameter not present. (Again, when working with VLSM/classless, you'll want to use subnets parameter.)

ashishrana Wed, 08/19/2015 - 08:26

while doing redistribution in OSPF from any other routing protocol, then we need to specify the keyword " subnets" in redistribution command. If we do not do so, it will throw the informational message stating that "Only classful networks will be redistributed". What it means is that if we are redistributing an eigrp subnet 10.1.1.0/28 in OSPF without  using "subnets" then it wont get in to OSPF. If there is a subnet 160.1.1.0/16 being redistributed in OSPF then it will enter in OSPF Topology because it is a "classful" subnet .

Therefore to successfully redistribute subnetted networks, we need to use "subnets" keyword. 

This happens only in OSPF I think. Similar details can be found in below link 

http://networkchap.com/ospf-redistribution-problem/

 

Actions

This Discussion