04-01-2018 06:50 PM - edited 03-08-2019 02:28 PM
I'm reading a CCNA book that has a 2 router running OSPF where one interface has a general network command of
network 192.168.0.0 0.0.255.2555 area 0
vs
network 192.168.1.12.2 0.0.0.0. area 0
network 192.168.1.24.2 0.0.0.0. area 0
network 192.168.1.2.2 0.0.0.0. area 0
Question is does it give an engineer more control of the more specific routes or whats the deal hear.
Whats the difference ?
04-01-2018 08:48 PM
Hi
Let's assume your router has 3 interfaces:
- 192.168.2.0/24
- 192.168.20.0/24
- 192.168.200.0/24
If your network statement is :
network 192.168.0.0 0.0.255.255 area 0
This means that all interfaces matching this statement, theyr networks will be advertised into ospf in area 0.
Now let's say, you don't want to advertise one interface on this supernet 192.168.0.0/16 or if you want to create a new interface to do an adjacency with another router in area 1, you won't be able to do it unless if you have specific network statements.
This is a choice made during a design and by planning the future.
Both solutions will work but as explained there are some limitations. By advertising a global subnet, all interfaces will be in the same area.
Personally i advertise subnets using the most precise network statement like:
network 192.168.1.1 0.0.0.0 area 0 or by doing a redistribute connected if i want to tag routes for future use.
04-05-2018 07:09 PM
You don't point out the limitation or benefits of either.
04-05-2018 09:18 PM - edited 04-05-2018 09:19 PM
Yes i gave you an example also.
Being specific with the network statement you will advertise only the interface associated to this subnet while advertising a bigger subnet with network statement, you'll force the router to integrate all its interfaces to be part of ospf if their subnets match the network command subnet.
With specific you can filter to tell which interface is part of ospf and on which area. With the largest subnet, you can't define it too much. All interfaces matching this large subnet will be part of the same area.
And if you create a loopback or interface that doesn't need to be advertised on ospf, with the larger subnet network command, if there's a match, you won't avoid it.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide