Unit 1: Network Infrastructure
This will allow you to demonstrate your networking skills, knowledge, and abilities, with a focus on enterprise-level switching, routing, and multicast components that support cross-platform (inter)operability and integration with the most recent software-defined technologies.

OSPF Configuration

How to Configure OSPF for Single Area

OSPF is very easy to set up in its most basic form. You need to use the router ospf PROCESS-ID global configuration command to turn on OSPF on a router before you can use it with other routing protocols like RIP and EIGRP. Next, use the network IP_ADDRESS WILDCARD_MASK AREA_ID command from the OSPF configuration mode to choose which interfaces OSPF will run on and which networks will be advertised.

While the Area ID must match across all nearby routers for a router to become a neighbor, the OSPF process number need not match across all routers to create a neighbor relationship.

To get things rolling, let’s begin with some fundamental OSPF routing protocol configuration. The topology of the network that we will utilize is as follows:

Pretend that the devices have their IP addresses and basic settings set up. Enabling OSPF on both routers is the first step in configuring OSPF. Then, using the following command sequence on both routers, we need to specify which network will be published in OSPF:

R1(config-router)#router ospf 1
R1(config-router)#network 10.0.10.0 0.0.0.255 area 0
R1(config-router)#network 192.16.0.0 0.0.255.255 area 0

R2(config-router)#router ospf 1
R2(config-router)#network 192.168.0.0 0.0.0.255 area 0
R2(config-router)#network 192.16.0.0 0.0.255.255 area 0

The network commands that were typed into both routers include subnets that are directly linked to both routers. The show ip ospf neighbors command can be typed on either router to make sure that they are now neighbors:

R1#show ip ospf neighbor
Neighbor ID Pri State Date Time Address Interface
192.168.0.2 1 FULL/BDR 00:00:32 192.16.0.2 FastEthernet0/1

We can use the display ip route command to confirm whether the routing updates were exchanged. Routes denoted by the letter O are all OSPF routes. Here is an example of what the command on R1 produced:

R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route

Gateway of last resort is not set

10.0.0.0/24 is subnetted, 1 subnets
C 10.0.10.0 is directly connected, FastEthernet0/0
C 192.16.0.0/16 is directly connected, FastEthernet0/1
O 192.168.0.0/24 [110/2] via 192.16.0.2, 00:03:44, FastEthernet0/1

The routing table shows that R1 has learned about the 192.168.0.0/24 network through OSPF.

OSPF Configuration for Multiple Areas

Setting up OSPF can be pretty simple, but it has a lot of extra features that can make things very complicated. We will set up a multiarea OSPF network and some other OSPF features in this case.

Take a look at this multiarea OSPF network. Let’s say that each device already has an IP address and some simple settings set up.

As an illustration, we have two OSPF areas, which are designated as area 0 and area 1. If you look at the network architecture that was just presented to you, you will notice that routers R1 and R3 are located in area 0 and area 1, respectively. As a result of his ability to connect to both regions, Router 2 is classified as an Area Border Router (ABR). By entering the following configurations on R1, we intend to achieve our goal of successfully advertising the subnets that are directly connected to R1 and R3:

R1(config-router)#router ospf 1
R1(config-router)#network 10.0.10.0 0.0.0.255 area 0
R1(config-router)#network 192.16.0.0 0.0.255.255 area 0
R1(config-router)#router-id 1.1.1.1

For this router, we used the router-id 1.1.1.1 command to enter the router ID by hand. That RID (router-id) will be used by the OSPF process to talk to other OSPF neighbors.

We just need to create a neighbor relationship with R2 and announce the directly linked subnet into OSPF because R1 only connects to R2.

R3’s configuration is similar, with one exception—the area number. Area 1 contains R3.

No Attachment Found
No Attachment Found