TechKnowSurge
Cisco CCNA 3.4
VideoNetworkFree

OSPF Configurations

OSPF configuration requires just two core commands to get a network up and running, covering process IDs, network statements, wildcard masks, and area assignments. This content builds a practical foundation before diving deeper into advanced OSPF concepts.

Complete this video to capture a CTF flag worth 1 point.

About this video

OSPF configuration is often perceived as complex, but a functional deployment requires only two commands: router ospf followed by a process ID, and a network statement specifying an address, wildcard mask, and area ID. The process ID is locally significant, meaning it identifies an OSPF instance on a specific router and has no impact on communication between routers. Using a consistent process ID across all routers is a common convention but is not a technical requirement. For environments running a single OSPF instance, any valid integer works as the process ID. The network statement performs two critical functions simultaneously. It designates which directly connected networks will be advertised to OSPF neighbors, and it activates OSPF on the interfaces whose IP addresses fall within the specified range. Wildcard masks accompany each network statement and work as the bitwise inverse of a subnet mask, with zero bits indicating positions that must match and one bits indicating positions that are ignored. A wildcard of 0.255.255.255 paired with a 10.0.0.0 address, for example, matches any address in the entire 10.0.0.0/8 range, effectively enabling OSPF on all interfaces within that space. OSPF areas provide a mechanism for dividing larger networks into smaller, more manageable segments, reducing the volume of link-state update traffic that must be processed across the entire topology. In a single-area deployment, best practice dictates the use of area zero, which serves as the backbone area in all OSPF designs. Beyond these foundational elements, more advanced configurations including hello interval tuning, passive interfaces, cost manipulation, OSPF priorities, and router ID assignment extend control over OSPF behavior and are addressed in subsequent material.

What you'll learn

What's covered

OSPF Configuration

Aligned to

Cisco CCNA
3.4 Configure and verify single area OSPFv2

Key terms

Open Shortest Path First
OSPF
A link-state interior gateway routing protocol that maintains a complete map of the network topology and uses Dijkstra's Shortest Path First algorithm to calculate optimal, loop-free routes. OSPF divides networks into hierarchical areas to improve scalability and supports VLSM and rapid convergence.
Routing Protocol
A protocol used by routers to communicate and share routing information to determine the best path for data.
Router
A network device that forwards data packets between networks based on IP addresses.
OSPF Process ID
A locally significant number that identifies a specific OSPF instance on a router, used to distinguish multiple OSPF processes running on the same device.
OSPF Network Statement
A configuration command that identifies which interfaces and directly connected networks will participate in the OSPF routing process.
Wildcard Mask
A 32-bit mask used in ACL statements and OSPF network commands where a 0 bit means the corresponding address bit must match and a 1 bit means it can be anything. Wildcard masks are the inverse of subnet masks and allow a single statement to match an entire range of IP addresses.
Subnet Mask
A 32-bit number that divides an IP address into network and host portions.
OSPF Area
A logical grouping of routers and networks within OSPF used to limit routing update traffic and scale large networks; Area 0 is the backbone area required in all OSPF deployments.

Topics

Ospf Routing Protocols Cisco Ios Wildcard Masks Network Configuration Networking

Transcript

I have said multiple times that link state protocols and OSPF are a little more complicated when you are rolling it out on your network, but it actually does not have to be. It can start out very simplistic, and it really is just two commands, so less than we implemented RIP with.

The commands are router ospf with the process ID, and then the network statement, where we do a network address with the wildcard, area, and area ID. So there are a couple more components in that, that we will be discussing. An example of that is router ospf 10, and then network 10.0.0.0 0.255.255.255 with an area of 0. These are the example of the commands that we will be actually putting in on our network.

The Process ID

The one thing that we need to talk about first of all here is this process ID. The process ID is specific to the router, and it really does not have much bearing on that router. It just separates out your different instances of OSPF. In this case you are just going to have one instance, so I can come up with any number. I just came up with 10 and I can put it in here.

For consistency purposes I am going to want to put ospf 10 on every single router, but it does not have to be, because it is the process ID, so it is identifying the process, or the OSPF instance. If I were to have multiple instances running on this router, then I would use multiple process IDs. So first of all, do not get hung up on that. You do not need to know a lot about it, except for just that it is router specific, and that we are going to come up with 10 and put the same one on our routers.

The Network Statement

Then we have the network statement. The network statement does two things for us. First of all, it identifies which networks are going to participate in the OSPF process, meaning whether a directly attached network is going to be advertised out or not. The other thing that it does is it identifies interfaces that are going to participate in this OSPF process, so which interfaces are going to send and receive OSPF updates.

What we have done here with this one right here is we have said that almost all of our networks that we have specified within our topology really fall under this 10.0.0.0 /8 network, and so we pretty much said that all interfaces and all networks are going to participate. For now, just know that that is what the network statement does.

The Wildcard Mask

Then we have the wildcard mask. Really what the wildcard mask is, is very similar to the subnet mask, but it is the reverse of the subnet mask most of the time. What I mean by that is, in the subnet mask this 255 ends up being all ones, and it says that each one of those bits is a network bit, and all of these zeros are host bits. So all it is doing is saying this is the network and these are going to specify the hosts on that network.

Well, a wildcard mask, generally speaking, is the opposite of a subnet mask. So where you have a 255 in the subnet mask, you have a zero in the wildcard mask, and it is all zeros. And then the rest of this, what it is specifying, is that those are wildcards. It does not matter if that is a one or a zero, you are going to ignore those bits. So this right here says all of the last 24 bits of this number, of this IP address, are going to be ignored. We do not care if it is a one or a zero. That is the wildcard part of this. So what you end up with is 0.255.255.255 if you are doing a /8.

OSPF Areas

The last thing that we will touch on is that OSPF areas allow us to break up our topology into smaller sections. With all of this traffic that is being sent back and forth, with all of these updates that are being sent back and forth, it really can swamp down your network, and the bigger your network is the more problematic that can be. So OSPF areas allow us to break it into smaller sections.

The best practice is that when you only have one area, which is what we are going to have on our network, then that area should be area 0. So for our area ID, for the purpose of most of this course, we are going to be using area 0.

Other Configurations

We do not need to get into a lot of the other configurations for us to at least initially set something up, but I thought I would mention them. One of them is going to be the OSPF hello intervals. There is a passive interface, and what a passive interface does. There is how we can manipulate OSPF costs, because we are definitely going to want to do that when it comes to OSPF. There are OSPF priorities, and OSPF router IDs.

About TechKnowSurge

TechKnowSurge builds IT and cybersecurity professionals through hands-on, concept-first training built around real understanding — not memorization. Free interactive tools, structured programs, and 25+ years of real-world experience, all in one place.

Explore free tools and programs →