Initial Configurations For OSPF Over A Point To Point Link: Document ID: 13687
Initial Configurations For OSPF Over A Point To Point Link: Document ID: 13687
Contents
Introduction Prerequisites Requirements Components Used Conventions OSPF over a PointtoPoint Link with IP Addresses on Serial Interfaces Network Diagram Configurations OSPF over a PointtoPoint Link with Unnumbered Interfaces Network Diagram Configurations Verify Verify the Configuration of OSPF with IP Addresses on Serial Interfaces Verify the Configuration of OSPF with Unnumbered Interfaces Troubleshoot Related Information
Introduction
On pointtopoint links such as HighLevel Data Link Control (HDLC) and PointtoPoint Protocol (PPP), Open Shortest Path First (OSPF) runs as a pointtopoint network type. This network type is enabled by default. This document shows sample configurations for OSPF over a pointtopoint link. The other network types that OSPF supports are Point to Multipoint, Broadcast, and NonBroadcast. In order to check the network type of an interface that runs OSPF, issue the show ip ospf interface command. The examples explained in this document work with both HDLC and PPP encapsulations.
Prerequisites
Requirements
Readers of this document should have some basic knowledge of OSPF routing protocol. For more information on OSPF routing protocol, refer to the Open Shortest Path First documentation.
Components Used
The information in this document applies to these software and hardware versions. Cisco 2500 routers Cisco IOS Software Release 12.2(27) that runs on routers The information in this document was created from the devices in a specific lab environment. All of the devices used in this document started with a cleared (default) configuration. If your network is live, make sure that you understand the potential impact of any command.
Conventions
For more information on document conventions, refer to the Cisco Technical Tips Conventions .
Network Diagram
Configurations
This section uses these configurations. Router1 Router2 Router1
Router1 ! interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial0 ip address 1.1.1.2 255.255.255.0 ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 ! Configures the Serial Interface S0 under OSPF area 0. !
Router2
Router2 ! interface Loopback0
ip address 2.2.2.2 255.255.255.255 ! interface Serial0 ip address 1.1.1.1 255.255.255.0 clockrate 2000000 ! router ospf 1 network 1.1.1.0 0.0.0.255 area 0 ! Configures the Serial Interface S0 under OSPF area 0..
Network Diagram
Configurations
This section uses these configurations. Router1 Router2 Router1
! interface Loopback0 ip address 3.3.3.3 255.255.255.255 ! interface Serial0 ip unnumbered loopback 0 ! Configures Serial 0 as an unnumbered interface.
encapsulation ppp ! Configures the Encapsulation on the interface as PPP. ! router ospf 1 network 3.3.3.0 0.0.0.255 area 0 ! Configures the Loopback Interface L0 under OSPF area 0. !
Router2
! interface Loopback0 ip address 2.2.2.2 255.255.255.255 ! interface Serial0 ip unnumbered loopback 0 ! Configures Serial 0 as an unnumbered interface. encapsulation ppp ! Configures the Encapsulation on the interface as PPP. ! router ospf 1 network 2.2.2.0 0.0.0.255 area 0 ! Configures the Loopback Interface L0 under OSPF area 0.. !
Verify
This section provides information you can use to confirm your configuration properly works. Certain show commands are supported by the Output Interpreter Tool (registered customers only) , which allows you to view an analysis of show command output.
This output shows that Router1 has one neighbor with a Router ID of 2.2.2.2, and has formed full adjacency with this neighbor. The address 1.1.1.1 is the IP address of the Serial0 interface on Router2. For additional information about the show ip ospf neighbor command, refer to What Does the show ip ospf neighbor Command Reveal? This is the output of the show ip ospf interface serial 0 command on Router1. This output shows the OSPF network type for interface Serial0 as pointtopoint.
Router1# show ip ospf interface serial 0 Serial0 is up, line protocol is up Internet Address 1.1.1.2/24, Area 0 Process ID 1, Router ID 3.3.3.3, Network Type POINT_TO_POINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_POINT, Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 Hello due in 00:00:05 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 2.2.2.2 Suppress hello for 0 neighbor(s)
Similarly, this example displays the output for the show ip ospf neighbor and the show ip ospf interface commands on Router2.
Router2# show ip ospf neighbor Neighbor ID Pri State 3.3.3.3 1 FULL/ Dead Time 00:00:32 Address 1.1.1.2 Interface Serial0
Router2# show ip ospf interface serial 0 Serial0 is up, line protocol is up Internet Address 1.1.1.1/24, Area 0 Process ID 1, Router ID 2.2.2.2, Network Type POINT_TO_POINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_POINT, Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 Hello due in 00:00:05 Index 1/1, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 3.3.3.3 Suppress hello for 0 neighbor(s)
Router1# show ip ospf interface serial 0 Serial0 is up, line protocol is up Internet Address 0.0.0.0/24, Area 0 Process ID 1, Router ID 3.3.3.3, Network Type POINT_TO_POINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_POINT, Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 Hello due in 00:00:08 Index 2/2, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 2.2.2.2 Suppress hello for 0 neighbor(s)
This example displays the output of the show ip ospf neighbor and show ip ospf interface serial 0 commands on Router2.
Router2#show ip ospf neighbor Neighbor ID Pri State 3.3.3.3 1 FULL/ Dead Time 00:00:30 Address 3.3.3.3 Interface Serial0
Router2# show ip ospf interface serial 0 Serial0 is up, line protocol is up Internet Address 0.0.0.0/24, Area 0 Process ID 1, Router ID 2.2.2.2, Network Type POINT_TO_POINT, Cost: 64 Transmit Delay is 1 sec, State POINT_TO_POINT, Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 Hello due in 00:00:08 Index 2/2, flood queue length 0 Next 0x0(0)/0x0(0) Last flood scan length is 1, maximum is 1 Last flood scan time is 0 msec, maximum is 0 msec Neighbor Count is 1, Adjacent neighbor count is 1 Adjacent with neighbor 3.3.3.3 Suppress hello for 0 neighbor(s)
This example shows the output of the show ip route command on Router1 with encapsulation PPP and the use of unnumbered interfaces.
Router1#show ip route Codes: C connected, S static, I IGRP, 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 ISIS, su ISIS summary, L1 ISIS level1, L2 ISIS level2 ia ISIS inter area, * candidate default, U peruser static route o ODR, P periodic downloaded static route Gateway of last resort is not set 2.0.0.0/32 2.2.2.2 3.0.0.0/32 3.3.3.3 is is is is subnetted, 1 subnets directly connected, Serial0 subnetted, 1 subnets directly connected, Loopback0
C C
This example displays the output of the show ip route command on Router 2 with encapsulation PPP and the use of unnumbered interfaces.
Router2#show ip route Codes: C connected, S static, I IGRP, 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 ISIS, su ISIS summary, L1 ISIS level1, L2 ISIS level2 ia ISIS inter area, * candidate default, U peruser static route o ODR, P periodic downloaded static route Gateway of last resort is not set 2.0.0.0/32 2.2.2.2 3.0.0.0/32 3.3.3.3 is is is is subnetted, 1 subnets directly connected, Loopback0 subnetted, 1 subnets directly connected, Serial0
C C
This example displays the output of the show ip route command on Router1 with encapsulation HDLC and the use of unnumbered interfaces.
Router1#show ip route Codes: C connected, S static, I IGRP, 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 ISIS, su ISIS summary, L1 ISIS level1, L2 ISIS level2 ia ISIS inter area, * candidate default, U peruser static route o ODR, P periodic downloaded static route Gateway of last resort is not set 2.0.0.0/32 2.2.2.2 3.0.0.0/32 3.3.3.3 is subnetted, 1 subnets [110/65] via 2.2.2.2, 00:00:08, Serial0 is subnetted, 1 subnets is directly connected, Loopback0
O C
This example displays output of the show ip route command on Router2 with encapsulation HDLC and the use of unnumbered interfaces.
Router1#show ip route Codes: C connected, S static, I IGRP, 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 ISIS, su ISIS summary, L1 ISIS level1, L2 ISIS level2 ia ISIS inter area, * candidate default, U peruser static route o ODR, P periodic downloaded static route Gateway of last resort is not set 2.0.0.0/32 is subnetted, 1 subnets 2.2.2.2 is directly connected, Loopback0 3.0.0.0/32 is subnetted, 1 subnets 3.3.3.3 [110/65] via 3.3.3.3, 00:01:28, Serial0
C O
Note: The output of the show ip route command might differ between PPP and HDLC encapsulations when IP unnumbered configuration is used on serial interfaces. PPP installs a host route to the IP address that is used on the serial interface at the other end as a directly connected network. If the same prefix is also learned through OSPF as in this configuration, it displays only as a connected route (as this show ip route output shows). This is because connected routes have a lower administrative distance than OSPF and are more preferred. You can change this behavior when you issue the no peer neighborroute command under the serial interfaces which prevents a host route from being installed and treats it as an OSPF route. This is not the case with HDLC because it does not install a host route. HDLC installs an OSPF route for the address on the other end when IP unnumbered is used.
Troubleshoot
For information on how to troubleshoot OSPF issues, refer to Troubleshooting OSPF.
Related Information
OSPF Routers Connected by a PointtoMultipoint Link OSPF Routers Connected by an Unnumbered Serial Link OSPF Neighbor States OSPF Technology Support Page Understanding and Configuring the ip unnumbered Command Technical Support & Documentation Cisco Systems
Contacts & Feedback | Help | Site Map 2012 2013 Cisco Systems, Inc. All rights reserved. Terms & Conditions | Privacy Statement | Cookie Policy | Trademarks of Cisco Systems, Inc.