To configure OSPF on a router, follow the steps below:
1. Enable OSPF on the router using the command “router ospf” followed by a process ID.
2. Configure OSPF areas using the command “area” followed by an area ID.
3. Assign loopback addresses to the router interfaces.
4. Configure OSPF network type on the interfaces using the “network” command.
5. Configure OSPF authentication using “ip ospf authentication” command.
6. Configure OSPF metrics using the “ip ospf cost” command.
7. Verify OSPF configurations using the “show ip ospf” command.
Note: OSPF configuration may vary based on the vendor and model of the router. It is important to consult the router documentation before configuring OSPF.