show ip ospf interface

Displays information about all or specific Open Shortest Path First (OSPF)-enabled interfaces.

show ip ospf interface [ ip-address ] [ brief ] [ ethernet unit/slot/port ] [ lag lag-id ] [ loopback number ] [ tunnel number ] [ ve vlan-id ]
ip-address
Specifies interface IP address in dotted decimal format.
brief
Displays brief summary information about the specified interface.
ethernet unit/slot/port
Specifies an Ethernet interface with the interface ID in unit/slot/port ID format.
lag lag-id
Specifies the Link Aggregation Group (LAG) virtual interface.
loopback number
Specifies a loopback port number, which ranges from 1 through 255..
tunnel number
Specifies a tunnel interface.
ve vlan-id
Specifies the virtual Ethernet (VE) VLAN number.

User EXEC mode

Use the brief keyword to limit the display to the following fields:

  • Interface
  • Area
  • IP address/Mask
  • Cost
  • State
  • Nbrs(F/C)

If enable password-display is configured on the device, the MD5 password is displayed in clear text in the output for this command. To prevent the MD5 password from being displayed in clear text, the enable password-display command should be used with the md5-fmt parameter. Refer to the enable password-display command for more information.

The show ip ospf interface command displays the following information:

Output field

Description

Interface

The type of interface type and the port number or number of the interface.

IP Address

The IP address of the interface.

Area

The OSPF area configured on the interface

Database Filter

The router’s configuration for blocking outbound LSAs on an OSPF interface.

If Not Configured is displayed, there is no outbound LSA filter configured. This is the default condition.

State

The state of the interface. Possible states include the following:

  • DR: The interface is functioning as the Designated Router for OSPFv2.
  • BDR: The interface is functioning as the Backup Designated Router for OSPFv2.
  • Loopback: The interface is functioning as a loopback interface.
  • P2P: The interface is functioning as a point-to-point interface.
  • Passive: The interface is up but does not take part in forming an adjacency.
  • Waiting: The interface is trying to determine the identity of the BDR for the network.
  • None: The interface does not take part in the OSPF interface state machine.
  • Down: The interface is unusable. No protocol traffic can be sent or received on such a interface.
  • DR other: The interface is a broadcast or NBMA network on which another router is selected to be the DR.
  • Active: The interface sends or receives all the OSPFv2 control packets and forms the adjacency.

default

Shows whether or not the default passive state is set.

Pri

The interface priority.

Cost

The configured output cost for the interface.

Interface bandwidth

The configured bandwidth on a tunnel interface for routing metric purposes only.

Options

OSPF Options (Bit7 - Bit0):

  • unused:1
  • opaque:1
  • summary:1
  • dont_propagate:1
  • nssa:1
  • multicast:1
  • external route capable:1
  • tos:1

Type

The area type:

  • Broadcast
  • Point to Point
  • Non-broadcast
  • Virtual Link

Events

OSPF interface event:

  • Interface_Up = 0x00
  • Wait_Timer = 0x01
  • Backup_Seen = 0x02
  • Neighbor_Change = 0x03
  • Loop_Indication = 0x04
  • Unloop_Indication = 0x05
  • Interface_Down = 0x06
  • Interface_Passive = 0x07

Timer intervals

The interval, in seconds, of the transmit-interval, retransmit-interval, hello-interval, and dead-interval timers.

Packets Received

Number of packets received from the server.

Packets Sent

Number of packets sent to the server.

Hello

Number of Hello packets.

Database

OSPF database.

LSA Req

LSA Upd

LSA update

LSA Ack

LSA acknowledgment.

Packet Errors

OSPF packet areas

Area mismatch

DR

The router ID (IPv4 address) of the Designated Router (DR).

BDR

The router ID (IPv4 address) of the Backup Designated Router (BDR).

Neighbor Count

The number of neighbors to which the interface is connected.

Adjacent Neighbor Count

The number of adjacent neighbor routers.

Neighbor

The IP address of the neighbor.

This example shows sample output from the show ip ospf interface command when the brief keyword is used.


device# # show ip ospf interface brief
Number of Interfaces is 1
Interface Area IP Addr/Mask Cost State Nbrs(F/C)
eth 1/1/2    0    16.1.1.2/24   1     down  0/0

The following example displays information about a specified OSPF-enabled virtual Ethernet (VE) interface.


device# show ip ospf interface ve 20

ve 20  admin up, oper up, ospf enabled, state up
     IP Address 21.21.21.22, Area 0
     Database Filter: Not Configured
     State BDR, Pri 1, Cost 1, Options 2, Type broadcast Events 31
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 3.3.3.3           Interface Address 21.21.21.21
     BDR: Router ID 2.2.2.2           Interface Address 21.21.21.22
                     Packets Received        Packets Sent
     Hello                      86374               86735
     Database                       2                   4
     LSA Req                        1                   0
     LSA Upd                      451                 907
     LSA Ack                      906                 451
     No Packet Errors!
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         21.21.21.21 [id 3.3.3.3] (DR)
     Authentication-Key: None
     MD5 Authentication: Key None, Key-Id None, Auth-change-wait-time 300

The following example displays information about a specified OSPF-enabled Ethernet interface, including the cost, where the cost is calculated using the default interface speed and auto cost.


device# show ip ospf interface ethernet 3/1/1

     e 3/1/1 admin up, oper up, ospf enabled, state up
     IP Address 89.0.0.2, Area 0
     Database Filter: Not Configured
     State BDR, Pri 1, Cost 1, Options 2, Type broadcast Events 3

The following example displays information about a specified OSPF-enabled Ethernet interface, including the cost, which has been calculated using the configured interface bandwidth and the default auto-cost.


device# show ip ospf interface ethernet 1/1/3

e 1/1/3 admin up, oper up, ospf enabled, state up
     IP Address 172.201.3.2, Area 0
     Database Filter: Not Configured
     State DR, Pri 1, Cost 34, Options 2, Type broadcast Events 5
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 192.168.3.1       Interface Address 172.201.3.2
     BDR: Router ID 192.168.1.1       Interface Address 172.201.3.1
                     Packets Received        Packets Sent
     Hello                         73                  79
     Database                       3                   2
     LSA Req                        0                   1
     LSA Upd                        4                   5
     LSA Ack                        5                   3
     No Packet Errors!
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         172.201.3.1 [id 192.168.1.1] (BDR)
     Authentication-Key: None
     MD5 Authentication: Key None, Key-Id None, Auth-change-wait-time 300

The following example displays information about a specified OSPF-enabled VE interface including OSPF BFD sessions for neighbors.


device# show ip ospf interface ve 10

ve 10 admin up, oper up, ospf enabled, state up
     IP Address 12.12.12.3, Area 0
BFD is enabled 
     Database Filter: Not Configured
     State DR, Pri 1, Cost 1, Options ------E-, Type broadcast Events 55183
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 0.0.0.2           Interface Address 12.12.12.3
     BDR: Router ID 0.0.0.1           Interface Address 12.12.12.6
                     Packets Received        Packets Sent
     Hello                      10029               10045
     Database                       3                   3
     LSA Req                        1                   1
     LSA Upd                       56                  60
     LSA Ack                       59                  55
     Packet Errors: None
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         12.12.12.6 [id 0.0.0.1] (BDR)
     Authentication-Key: None
     MD5 Authentication: Key None, Key-Id None, Auth-change-wait-time 300

The following example displays information about a specified OSPF-enabled VE interface including information for port traffic statistics.

device> show ip ospf interface ve 42

ve 42  admin up, oper up, ospf enabled, state up
     IP Address 42.1.1.1, Area 1.1.1.1
     Database Filter: Not Configured
     State BDR, Pri 1, Cost 1, Options 2, Type broadcast Events 2
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 135.1.1.1         Interface Address 42.1.1.35
     BDR: Router ID 102.1.1.1         Interface Address 42.1.1.1
                     Packets Received        Packets Sent
     Hello                         11                  11
     Database                       0                   0
     LSA Req                        0                   0
     LSA Upd                        0                   0
     LSA Ack                        0                   0
     Packet Errors:
      Area mismatch 22,
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         42.1.1.35 [id 135.1.1.1] (DR)
     In-Use Authentication:         None, Key:     None, Key-Id: None

The following example shows a portion of sample output from the show ip ospf intervace command when the enable password-display feature is not configured. The MD5 password is not displayed.


device> show ip ospf interface ve 747

ve 747  admin up, oper up, ospf enabled, state up
     IP Address 7.4.7.1, Area 0
     Database Filter: Not Configured
     State BDR, Pri 1, Cost 1, Options 2, Type broadcast Events 2
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 6.6.6.2           Interface Address 7.4.7.2
     BDR: Router ID 10.254.10.254     Interface Address 7.4.7.1
                     Packets Received        Packets Sent
     Hello                        202                 199
     Database                       3                   2
     LSA Req                        0                   1
     LSA Upd                        4                   3
     LSA Ack                        3                   3
     No Packet Errors!
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         7.4.7.2 [id 6.6.6.2] (DR)
     In-Use Authentication:          md5, Key:      ********, Key-Id:    1

The following example shows a portion of sample output from the show ip ospf interface command when the enable password-display feature is configured. The MD5 password is displayed in clear text.


show ip ospf interface ve 747

ve 747  admin up, oper up, ospf enabled, state up
     IP Address 7.4.7.1, Area 0
     Database Filter: Not Configured
     State BDR, Pri 1, Cost 1, Options 2, Type broadcast Events 2
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 6.6.6.2           Interface Address 7.4.7.2
     BDR: Router ID 10.254.10.254     Interface Address 7.4.7.1
                     Packets Received        Packets Sent
     Hello                        203                 200
     Database                       3                   2
     LSA Req                        0                   1
     LSA Upd                        4                   3
     LSA Ack                        3                   3
     No Packet Errors!
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         7.4.7.2 [id 6.6.6.2] (DR)
     In-Use Authentication:          md5, Key:       minerdi, Key-Id:    1

The following example shows a portion of sample output from the show ip ospf interface command when the enable password-display command is used with the md5-fmt parameter. The password is displayed in MD5 format.


show ip ospf interface ve 747   

ve 747  admin up, oper up, ospf enabled, state up
     IP Address 7.4.7.1, Area 0
     Database Filter: Not Configured
     State BDR, Pri 1, Cost 1, Options 2, Type broadcast Events 2
     Timers(sec): Transmit 1, Retrans 5, Hello 10, Dead 40
     DR:  Router ID 6.6.6.2           Interface Address 7.4.7.2
     BDR: Router ID 10.254.10.254     Interface Address 7.4.7.1
                     Packets Received        Packets Sent
     Hello                        205                 201
     Database                       3                   2
     LSA Req                        0                   1
     LSA Upd                        4                   3
     LSA Ack                        3                   3
     No Packet Errors!
     Neighbor Count = 1, Adjacent Neighbor Count= 1
     Neighbor:         7.4.7.2 [id 6.6.6.2] (DR)
     In-Use Authentication:          md5, Key: $Nj1nblVAPQ==, Key-Id:    1
Release version Command history
08.0.30 This command was modified to include configured bandwidth status.
08.0.92 The packet error section of the output for this command was modified to include more error counters for port traffic statistics.
08.0.92a The output for this command was modified so that the MD5 password is not displayed in clear text when enable password-display is configured.