< Home

display ospf routing

Function

The display ospf routing command displays the OSPF routing table.

Format

display ospf [ process-id ] routing [ ip-address [ mask | mask-length ] ] [ interface interface-type interface-number ] [ nexthop nexthop-address ]

display ospf [ process-id ] routing router-id [ router-id ]

Parameters

Parameter Description Value
process-id Specifies the ID of an OSPF process. The value is an integer ranging from 1 to 65535.
ip-address Specifies the IP address. In dotted decimal notation.
mask Specifies the subnet mask. In dotted decimal notation.
mask-length Specifies the mask length. The value is an integer ranging from 0 to 32.
interface-type Specifies the type of the interface. -
interface-number Specifies the number of the interface. -
nexthop nexthop-address Displays the route with the specified next hop IP address. -
router-id router-id Specifies the router ID of a destination router. In dotted decimal notation.

Views

All views

Default Level

1: Monitoring level

Usage Guidelines

By using this command with different parameters, you can view the routes of a specified interface or next hop.

The command output can help you troubleshoot OSPF faults.

Example

# Display the OSPF routing table.

<sysname> display ospf routing
          OSPF Process 1 with Router ID 4.4.4.4
                   Routing Tables
 
 Routing for Network
 Destination        Cost  Type       NextHop         AdvRouter       Area
 172.16.1.0/24      4     Inter-area 192.168.2.1     2.2.2.2         0.0.0.2
 172.17.1.0/24      1     Transit    172.17.1.1      4.4.4.4         0.0.0.2
 192.168.0.0/24     2     Inter-area 192.168.2.1     2.2.2.2         0.0.0.2
 192.168.1.0/24     3     Inter-area 192.168.2.1     2.2.2.2         0.0.0.2
 192.168.2.0/24     1     Stub       192.168.2.2     4.4.4.4         0.0.0.2

 Routing for ASEs
 Destination    Cost      Type       Tag         NextHop         AdvRouter
 10.0.0.0/8     1         Type2      1           192.168.2.1     1.1.1.1

 Total Nets: 6
 Intra Area: 2  Inter Area: 3  ASE: 1  NSSA: 0
Table 1 Description of the display ospf routing command output

Item

Description

Destination

Destination network

Cost

Cost of the route to the destination address

Type

Type of the destination network:

  • Inter-area: indicates inter-area routes.

  • Intra-area: indicates intra-area routes.

    • Stub: indicates the routes advertised by router LSAs, which correspond to the direct routes of non-broadcast and non-NBMA networks.

    • Transit: indicates the routes advertised by network LSAs.

NextHop

Next hop address to the destination address

AdvRouter

Advertising router

Area

Area ID

Tag

Tag of the external route

Total Nets

Total number of networks in an area, between areas, in ASE areas, and in NSSAs.

Intra Area

Total number of intra-area networks (that is, stub networks and transit networks)

Inter Area

Total number of inter-area networks

ASE

Total number of networks in the ASE area

NSSA

Total number of networks in the NSSA

# Display information about the OSPF routes to the device with the specified IP address.

<sysname> display ospf routing 10.5.6.0
          OSPF Process 1 with Router ID 3.3.3.3

 Destination : 10.5.6.0/24
 AdverRouter : 5.5.5.5                  Area      : 0.0.0.1
 Cost        : 20                       Type      : Transit
 NextHop     : 10.11.11.5               Interface : GigabitEthernet0/0/1
 Priority    : Low                      Age       : 00h00m10s
 Backup NextHop : 10.2.6.6              Backup Interface : GigabitEthernet0/0/3
 Backup Type : LFA LINK-NODE
Table 2 Description of the display ospf routing ip-address command output

Item

Description

Interface

Outbound interface of the next hop

Priority

OSPF convergence priority:
  • Critical
  • High
  • Medium
  • Low

Age

Lifetime of a route

Backup NextHop

Address of the backup next hop

Backup Interface

Outbound interface of the backup next hop

Backup Type

Type of the backup next hop:

  • LFA LINK: indicates that the backup route is under link protection.
  • LFA NODE: indicates that the backup route is under node protection.
  • LFA LINK-NODE: indicates that the backup route is under link-node dual protection.

# Display the routes to an OSPF device.

<sysname> display ospf routing router-id
          OSPF Process 1 with Router ID 1.1.1.1

                  Router Type URT Routing Tables

 RtType     Destination     Area            Cost  Nexthop         Type
 Intra-area 5.5.5.5         0.0.0.0         4     10.0.0.2        Normal
 Intra-area 4.4.4.4         0.0.0.0         3     10.0.0.2        Normal
 Intra-area 3.3.3.3         0.0.0.0         2     10.0.0.2        Normal
 Intra-area 2.2.2.2         0.0.0.0         1     10.0.0.2        Normal
Table 3 Description of the display ospf routing router-id command output

Item

Description

RtType

Type of the destination network:

  • Inter-area: indicates inter-area routes.

  • Intra-area: indicates intra-area routes.

    • Stub: indicates the routes advertised by router LSAs, which correspond to the direct routes of non-broadcast and non-NBMA networks.

    • Transit: indicates the routes advertised by network LSAs.

Type

Router type:
  • Normal
  • ABR
  • ASBR
  • ABR/ASBR

# Display routes to the OSPF device with the router ID being 4.4.4.4.

<sysname> display ospf routing router-id 4.4.4.4
           OSPF Process 1 with Router ID 5.5.5.5

 Destination : 4.4.4.4                  Route Type : Intra-area
 Area        : 0.0.0.10                 AdvRouter  : 4.4.4.4
 Type        : ASBR                     Age        : 0x411c41
 URT Cost    : 1
 NextHop     : 10.1.14.4                Interface  : GigabitEthernet0/0/1
 Backup Nexthop : 10.2.13.3             Backup Interface : GigabitEthernet0/0/3
 Backup Type : LFA LINK
Table 4 Description of the display ospf routing router-id command output

Item

Description

Route Type

Type of the destination network:

  • Inter-area: indicates inter-area routes.

  • Intra-area: indicates intra-area routes.

    • Stub: indicates the routes advertised by router LSAs, which correspond to the direct routes of non-broadcast and non-NBMA networks.

    • Transit: indicates the routes advertised by network LSAs.

URT Cost

Cost of the unicast routing table

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >