2.7.1 Packet Tracer - Single-Area OSPFv2 Configuration

3 min read 9 days ago
Published on Aug 25, 2025 This response is partially generated with the help of AI. It may contain inaccuracies.

Table of Contents

Introduction

This tutorial provides a step-by-step guide for configuring Single-Area OSPFv2 in Cisco Packet Tracer. Open Shortest Path First (OSPF) is a popular routing protocol used in IP networks. This guide is designed for those studying for the CCNA certification and aims to help you understand and implement OSPF in a simulated environment.

Step 1: Set Up the Network Topology

  1. Open Cisco Packet Tracer.
  2. Create the following devices:
    • 2 Routers (e.g., Router0 and Router1)
    • 2 PCs (PC0 and PC1) connected to each router.
  3. Connect the devices using appropriate cables:
    • Use straight-through cables for connecting routers to PCs.
    • Use serial cables for inter-router connections.

Step 2: Configure Basic Router Settings

  1. Access Router0 and enter the CLI mode.

  2. Set the hostname:

    Router0> enable
    Router0# configure terminal
    Router0(config)# hostname Router0
    
  3. Assign IP addresses to each interface:

    • For Router0:
      Router0(config)# interface GigabitEthernet0/0
      Router0(config-if)# ip address 192.168.1.1 255.255.255.0
      Router0(config-if)# no shutdown
      Router0(config-if)# exit
      
      Router0(config)# interface Serial0/0/0
      Router0(config-if)# ip address 10.0.0.1 255.255.255.252
      Router0(config-if)# no shutdown
      Router0(config-if)# exit
      
  4. For Router1, repeat the process:

    • Set the hostname to Router1.
    • Assign IP addresses:
    Router1(config)# interface GigabitEthernet0/0
    Router1(config-if)# ip address 192.168.2.1 255.255.255.0
    Router1(config-if)# no shutdown
    Router1(config-if)# exit
    
    Router1(config)# interface Serial0/0/0
    Router1(config-if)# ip address 10.0.0.2 255.255.255.252
    Router1(config-if)# no shutdown
    Router1(config-if)# exit
    

Step 3: Enable OSPF on the Routers

  1. On Router0, enter OSPF configuration mode:

    Router0(config)# router ospf 1
    Router0(config-router)# network 192.168.1.0 0.0.0.255 area 0
    Router0(config-router)# network 10.0.0.0 0.0.0.3 area 0
    
  2. On Router1, perform the same steps:

    Router1(config)# router ospf 1
    Router1(config-router)# network 192.168.2.0 0.0.0.255 area 0
    Router1(config-router)# network 10.0.0.0 0.0.0.3 area 0
    

Step 4: Verify OSPF Configuration

  1. Use the show ip route command on both routers to see the OSPF routes:

    Router0# show ip route
    Router1# show ip route
    
  2. Check OSPF neighbors to ensure routers can communicate:

    Router0# show ip ospf neighbor
    Router1# show ip ospf neighbor
    

Step 5: Test Connectivity

  1. From PC0, ping PC1 to test connectivity:

    • Open the command prompt on PC0 and run:
    ping 192.168.2.2
    
  2. If the pings are successful, OSPF is functioning correctly.

Conclusion

In this tutorial, you learned how to configure Single-Area OSPFv2 in Cisco Packet Tracer. You set up the network topology, configured router settings, enabled OSPF, verified the configurations, and tested connectivity. Next steps may include exploring multi-area OSPF configurations or experimenting with advanced OSPF features like route summarization and authentication.