Config Lab: Multi-area OSPF 2

Wendell Odom
By Wendell Odom September 21, 2021 19:05

A router configuration can enable OSPF on an interface directly using the ip ospf interface subcommand. In fact, the configuration is more direct and obvious than the old traditional use of the OSPF network subcommand. This lab combines OSPF interface configuration with a multi-area OSPF design, with a little extra configuration related to OSPF router IDs thrown in for variety.

All about Config Labs

The blog has a series of lab exercises called “Config Labs.” Each lab presents a topology with the relevant initial configuration for each device. The lab also lists new requirements, after which you should create the additional configuration to meet those requirements. You can do the lab on paper, in a text editor, or use software tools like Cisco Packet Tracer or Cisco Modeling Labs.

Once you have created your answer, you can click various tabs at the bottom of this post to see the lab answers, comments about the lab, and other helpful information.

The Lab Exercise

Requirements

Configure multi-area OSPFv2 (that is, OSPF for IPv4) on the four routers shown in the figure. Use the area design shown in the figure. The configuration should use the interface subcommand ip ospf to enable OSPF on each interface, and should use no network commands in OSPF configuration mode. The specific rules for this lab are:

  • Use an OSPF process-ID of 50 on all routers
  • Use only ip ospf interface subcommands to enable OSPF on an interface
  • Use the following OSPF router IDs, and make each router use the method listed below when the router chooses its router ID:
    • Core1: 1.1.1.1 (explicitly configured)
    • Core2: 2.2.2.2 (explicitly configured)
    • Branch1: 172.30.99.1 (Based on interface loopback0 address of 172.30.99.1/32)
    • Branch2: 172.30.99.2 (Based on interface loopback0 address of 172.30.99.2/32)
  • Use all default OSPF parameters unless otherwise requested.
  • Assume all device interfaces shown in the lab are up, working and with correct IP addresses assigned.

Figure 1: Multi-area OSPF Topology

 

Initial Configuration

Example 1, 2, 3 and 4 show the beginning configuration state of Core1, Core2, Branch1 and Branch2.

Example 1: Core1 Config

 

Example 2: Core2 Config

 

Example 3: Branch1 Config

 

Example 4: Branch2 Config

Answer Options - Click Tabs to Reveal

You can learn a lot and strengthen real learning of the topics by creating the configuration – even without a router or switch CLI. In fact, these labs were originally built to be used solely as a paper exercise!

To answer, just think about the lab. Refer to your primary learning material for CCNA, your notes, and create the configuration on paper or in a text editor. Then check your answer versus the answer post, which is linked at the bottom of the lab, just above the comments section.

You can also implement the lab using the Cisco Packet Tracer network simulator. With this option, you use Cisco’s free Packet Tracer simulator. You open a file that begins with the initial configuration already loaded. Then you implement your configuration and test to determine if it met the requirements of the lab.

(Use this link for more information about Cisco Packet Tracer.)

Use this workflow to do the labs in Cisco Packet Tracer:

  1. Download the .pkt file linked below.
  2. Open the .pkt file, creating a working lab with the same topology and interfaces as the lab exercise.
  3. Add your planned configuration to the lab.
  4. Test the configuration using some of the suggestions below.

Download this lab’s Packet Tracer File

You can also implement the lab using Cisco Modeling Labs – Personal (CML-P). CML-P (or simply CML) replaced Cisco Virtual Internet Routing Lab (VIRL) software in 2020, in effect serving as VIRL Version 2.

If you prefer to use CML, use a similar workflow as you would use if using Cisco Packet Tracer, as follows:

  1. Download the CML file (filetype .yaml) linked below.
  2. Import the lab’s CML file into CML and then start the lab.
  3. Compare the lab topology and interface IDs to this lab, as they may differ (more detail below).
  4. Add your planned configuration to the lab.
  5. Test the configuration using some of the suggestions below.

Download this lab’s CML file!

 

Network Device Info:

The CML topology matches the lab topology.

Lab Answers Below: Spoiler Alert

Lab Answers: Configuration (Click Tab to Reveal)

Answers

Figure 1: Multi-area OSPF Topology

 

Example 1: Core1 Config

 

Example 2: Core2 Config

 

Example 3: Branch1 Config

 

Example 4: Branch2 Config

Commentary, Issues, and Verification Tips (Click Tabs to Reveal)

Commentary

For this lab you are tasked with configuring the four different routers with OSPF and placing each of the interfaces into their respective areas by using ip ospf interface subcommands. This style of OSPF configuration can be simple to configure, especially if you have good documentation about router interfaces and areas. This lab supplies a figure with the routers, interface numbers, and areas. For about half of the requirements of this lab, all you have to do is issue a command like ip ospf 50 area 0 or similar under each interface.

Work through examples 1 through 4, focusing on only the ip ospf commands under each interface. Compare those commands to Figure 1. You should see the ip ospf 50 area 0 command on both Core1 and Core 2, under the interfaces that connect Core1 and Core2. This command references each router’s local process ID (50), and the area number into which to put that link. Continuing through the various examples:

  • Router Branch1 uses the same ip ospf 50 area 10 command on both interfaces, enabling OSPF process 50 on both, and placing both in area 10.
  • Router Branch2 uses the same ip ospf 50 area 20 command on both interfaces, enabling OSPF process 50 on both, and placing both in area 20.
  • Router Core1 uses the ip ospf 50 area 10 command on its G0/2 interface (which connects to router Branch1), placing that link into area 10.
  • Router Core2 uses the ip ospf 50 area 20 command on its G0/2 interface (which connects to router Branch1), placing that link into area 20.

As for the routers’ process IDs, the lab asks that all routers use process ID 50. Note that all show the router ospf 50 command as a result.

Finally, on the topic of OSPF router IDs (RIDs), the requirements asked you to explicitly configure the RID on Core1 and Core2, so those routers list the router-id 1.1.1.1 and router-id 2.2.2.2 commands, respectively. For the two branch routers, just for variety, the lab asked you to let these routers set their RID based on the IP addresses of their loopback0 interfaces. To make that work, you have to first create the loopback interface (interface loopback 0), and then configure the IP address. (Note that if you tried this on your own lab, you need to create the loopback interface first, before bringing up the OSPF process, so that the loopback interface is up when OSPF comes up.)

Known Issues in this Lab

This section of each Config Lab Answers post hopes to help with those issues by listing any known issues with Packet Tracer related to this lab. In this case, the issues are:

# Summary Detail
1 None No known issues related to this lab.

 

Why Would Cisco Packet Tracer Have Issues?

(Note: The below text is the same in every Config Lab.)

Cisco Packet Tracer (CPT) simulates Cisco routers and switches. However, CPT does not run the same software that runs in real Cisco routers and switches. Instead, developers wrote CPT to predict the output a real router or switch would display given the same topology and configuration – but without performing all the same tasks, an actual device has to do. On a positive note, CPT requires far less CPU and RAM than a lab full of devices so that you can run CPT on your computer as an app. In addition, simulators like CPT help you learn about the Cisco router/switch user interface – the Command Line Interface (CLI) – without having to own real devices.

CPT can have issues compared to real devices because CPT does not run the same software as Cisco devices. CPT does not support all commands or parameters of a command. CPT may supply output from a command that differs in some ways from what an actual device would give. Those differences can be a problem for anyone learning networking technology because you may not have experience with that technology on real gear – so you may not notice the differences. So this section lists differences and issues that we have seen when using CPT to do this lab.

Beyond comparing your answers to this lab’s Answers post, you can test in Cisco Packet Tracer (CPT) or Cisco Modeling Labs (CML). In fact, you can and should explore the lab once configured. For this lab, once you have completed the configuration, try these verification steps. 

  1. Verify the OSPF neighbor relationships with the show ip ospf neighbor command. The two core routers should list two neighbors each, and the two branch routers should list one neighbor each.
  2. Check the routing tables, using the show ip route command, to ensure that all known networks have been learned on each device. Each router should list five subnets, with 3 subnets learned by OSPF.
  3. From the branch routers, also test connectivity with the ping command. For instance, on router Branch1, use the ping 172.30.1.65 source 172.30.1.1 command to issue an extended ping from Branch1’s G0/2 interface IP address (172.30.1.1) to router Branch2’s G0/2 interface address (172.30.1.65).

More Labs with Related Content!

Config Lab: Multi-area OSPF 1
Config Lab: OSPF DR Priority
Wendell Odom
By Wendell Odom September 21, 2021 19:05
Write a comment

No Comments

No Comments Yet!

Let me tell You a sad story ! There are no comments yet, but You can be first one to comment this article.

Write a comment
View comments

Write a comment

Comment; Identify w/ Social Media or Email

Subscribe

Subscribe to our mailing list and get interesting stuff and updates to your email inbox.

Thank you for subscribing.

Something went wrong.

Search

Categories