Introduction to OSPF

Hello Ugo

These commands are not the same. They do very different things.

The config that uses the network command simply tells the router to allow all networks configured on local interfaces of the router that fall within the 10.2.0.0/16 range to participate in OSPF. In other words, if an interface’s IP address is within 10.2.0.0/16, then the subnet of that interface is advertised using OSPF.

The area range command can only be applied at an ABR and it is used to perform route summarization. It takes all learned prefixes from within area 1 that fall within the 10.2.0.0/16 range, and summarizes them before advertising them to other areas. This way you can consolidate multiple OSPF LSAs into a single summarized LSA making OSPF more efficient. More about the area range command can be found at this lesson:

You can also learn more about it at this Cisco command reference:

I hope this has been helpful!

Laz