sh ip ospf int br

sh ip ospf int  < int name >

sh ip ospf database

sh ip ospf border-routers

sh ip ospf traffic

sh ip ospf database router < router id >


sh ip ospf int br


Router#sh ip ospf int br

Interface PID Area IP Address/Mask Cost State Nbrs F/C

Lo0     100   0     1       LOOP        0/0

Gi1/2   100   0    1       DR            1/1

Gi2/2  100   0      1       BDR           1/1

Vl696   100  0    1         BDR        1/1

Vl2      100   0     1         DOWN    0/0



==> Output shows all the physical & virtual interfaces on logged in device, over which OSPF is enabled.

Example: Gi2/2 is physical interface & Vl696 is the virtual interface.

==> Here, PID represens the process id of OSPF, to which any particular interface belongs.

Example: Gi2/2 & Vl696, both belongs to process id 100.

sh ip ospf int < int name >


Router#sh ip ospf int  GigabitEthernet1/2

GigabitEthernet1/2 is up, line protocol is up (connected)

Internet Address,  Area 0

Process ID 100, Router ID, Network Type BROADCAST, Cost: 1

Transmit Delay is 1 sec, State DR, Priority 1

Designated Router (ID), Interface address

Backup Designated router (ID), Interface address

Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5



==> Here, network type is broadcast

==> Hello, Dead, Wait, Re-transmit  time intervals are 10, 40, 40 & 5

==> Internet address is the interface ip address on the logged in device, over which OSPF is enabled

Example: is the ip address of interface GigabitEthernet1/2

==> Router ID = Designated ID =, it means device itself is DR.


sh ip ospf database


MPLS#sh ip ospf database

OSPF Router with ID ( (Process ID 100)

Router Link States (Area 0)              / LSA-1 /

Link ID     ADV Router Age Seq# Checksum Link count 386 0x80028B40 0x009926 50 483 0x8000C4C4 0x00F601 5 1019 0x8000A725 0x008477 1


Net Link States (Area 0)         / LSA-2 /

Link ID       ADV Router Age Seq# Checksum 257 0x80007BF7 0x005834 1768 0x8000C3DF 0x0018FB 1201 0x8000C3D4 0x005859


Summary Net Link States (Area 0)         / LSA-3 /

Link ID         ADV Router Age Seq# Checksum 625 0x8000A0F3 0x00FA35 12 0x80003044 0x009DF2

Summary ASB Link States (Area 0)           / LSA-4 /

Link ID          ADV Router Age Seq# Checksum 625 0x80007231 0x009F45 12 0x80001771 0x00DF3F


Type-5 AS External Link States         / LSA-5 /

Link ID        ADV Router Age Seq# Checksum Tag 1242 0x800091D9 0x006CE5 65225 365 0x800091DB 0x003141 65225



Output shows database of all the subnets or routes learned from different LSA-types.

First line shows Router ID of the device, which is


sh ip ospf border-routers


MPLS#sh ip ospf border-routers

OSPF Process 100 internal Routing TableCodes: i – Intra-area route, I – Inter-area route

i [3] via, GigabitEthernet1/1, ASBR, Area 0, SPF 13514

I [13] via, GigabitEthernet2/2, ASBR, Area 0, SPF 13514

I [13] via, GigabitEthernet1/2, ASBR, Area 0, SPF 13514

I [14] via, GigabitEthernet1/1, ASBR, Area 0, SPF 13514

i [2] via, GigabitEthernet1/2, ABR/ASBR, Area 0, SPF 13514


==> Output shows all the border routers, including both ABR & ASBR.

==> is the RID of ASBR learned.

==> GigabitEthernet1/1 is the OSPF enabled interface on logged in device, through which ASBR

==> is the interface ip of next hop device, through ASBR is learned

sh ip ospf traffic


4507#sh ip ospf traffic

Interface statistics:Interface Loopback0  

OSPF packets received/sent

Invalid Hellos DB-des LS-req LS-upd LS-ack Total

Rx: 0 0 0 0 0 0 0

Tx: 0 0 0 0 0 0 0

OSPF header errors

Length 0, Auth Type 0, Checksum 0, Version 0,

Bad Source 0, No Virtual Link 0, Area Mismatch 0,

No Sham Link 0, Self Originated 0, Duplicate ID 0,

Hello 0, MTU Mismatch 0, Nbr Ignored 0,

LLS 0, Unknown Neighbor 0, Authentication 0,

TTL Check Fail 0,

OSPF LSA errors

Type 0, Length 0, Data 0, Checksum 0


==> Output shows stats like different type of packets transferring ( Tx / Rx ) for every individual interface.

==> It is showing all the error types also.


sh ip ospf database router  < router id >


MPLS#sh ip ospf database router

OSPF Router with ID ( (Process ID 100)

Router Link States (Area 0)

LS age: 1940

Options: (No TOS-capability, DC)

LS Type: Router Links

Link State ID:

Advertising Router:

LS Seq Number: 8000C4C3

Checksum: 0xF8FF

Length: 84

Number of Links: 5

Link connected to: a Stub Network

(Link ID) Network/subnet number:

(Link Data) Network Mask:

Number of TOS metrics: 0

TOS 0 Metrics: 1


==> Login to any device in the OSPF network & You can check above mentioned details for any of the OSPF enabled router in the network.

==> Number of Links: 5, means on router with RID ( ), OSPF is enabled on 5 interfaces.
==> Link connected to: a Stub Network, means out of above mentioned five interfaces, one interface is connected to Stub network. Similar to this, details of remaining 4 interfaces will also be given.







Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s