Basic OSPF Configuration and Troubleshooting on Cisco Routers
- February 24, 2024
- Posted by: Lyfey Technologies
- Categories: Cisco, Networking

In our previous article, we demonstrated how to configure basic OSPF functionalities on Huawei Routers, check out this article for configuring OSPF on Huawei: https://lyfeytech.co.ke/introduction-to-ospf-and-basic-configuration-on-huawei-devices/.
In this article, we demonstrate how to configure OSPF basic functionalities on Cisco routers.
Lab Diagram: We have 4 routers R1, R2, R3, and R4. R2 is our ABR(Area Border Router) connecting Area0 and Area1.

Router Configurations:
***********************************R1
enable
configure terminal
hostname Router
interface Loopback0
ip address 1.1.1.1 255.255.255.255
!
interface FastEthernet0/0
ip address 10.250.10.0 255.255.255.254
duplex auto
speed auto
!
router ospf 10
log-adjacency-changes
network 1.1.1.1 0.0.0.0 area 1
network 10.250.10.0 0.0.0.1 area 1
!
exit
write
*********************************R2
enable
configure terminal
hostname R2
interface Loopback0
ip address 2.2.2.2 255.255.255.255
!
interface FastEthernet0/0
ip address 10.250.10.1 255.255.255.254
duplex auto
speed auto
!
interface FastEthernet0/1
ip address 10.250.10.2 255.255.255.254
duplex auto
speed auto
!
router ospf 10
router-id 2.2.2.2
log-adjacency-changes
network 2.2.2.2 0.0.0.0 area 1
network 10.250.10.0 0.0.0.1 area 1
network 10.250.10.2 0.0.0.1 area 0
!
exit
write
**********************************R3
enable
!
configure terminal
hostname R3
!
interface Loopback0
ip address 3.3.3.3 255.255.255.255
!
interface FastEthernet0/0
description TO_R2_fa0/1
ip address 10.250.10.3 255.255.255.254
duplex auto
speed auto
!
interface FastEthernet0/1
description TO_R4_fa0/0
ip address 10.250.10.4 255.255.255.254
duplex auto
speed auto
!
router ospf 10
router-id 3.3.3.3
log-adjacency-changes
network 3.3.3.3 0.0.0.0 area 0
network 10.250.10.2 0.0.0.1 area 0
network 10.250.10.4 0.0.0.1 area 0
!
exit
write
***********************************R4
enable
configure terminal
!
hostname R4
!
interface Loopback0
ip address 4.4.4.4 255.255.255.255
!
interface FastEthernet0/0
description TO_R3_fa0/1
ip address 10.250.10.5 255.255.255.254
duplex auto
speed auto
!
interface FastEthernet0/1
no ip address
shutdown
duplex auto
speed auto
!
router ospf 10
router-id 4.4.4.4
log-adjacency-changes
network 4.4.4.4 0.0.0.0 area 0
network 10.250.10.4 0.0.0.1 area 0
!
exit
write
Verification:
Check the OSPF adjacency status on routers using command ” show ip ospf neighbor detail” | ” show ip ospf neighbor”.

Check the OSPF interfaces on routers using the command ” show ip ospf interfaces”

Check the OSPF LSA on the routers using the command ” show ip ospf database”

Check OSPF routers on the routers using the command ” show ip route ospf”

If you face any challenges when configuring OSPF in your lab, check out this article on OSPF troubleshooting OSPF troubleshooting guide