cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1646
Views
1
Helpful
3
Replies

OSPF LSDB size

yaroneis
Level 1
Level 1

I am looking for a way to track the size of the OSPF LSDB, or to calculate its size. can it be done via CLI? any calculations for this?

Thanks! Yaron

1 Accepted Solution

Accepted Solutions

smahbub
Level 6
Level 6

With show ip ospf database database-summary you get the type and number of routes you have and with the formulas below you can figure out the size you are occupying with the LSAs OSPF Memory Calculation All fields in the LSA's were calculated from what RFC 1247 states. Following constants were used

#define RLS_HEADER 24

#define RL_SIZE 12

#define NLS_HEADER 24

#define SIZE_ROUTER 4

#define SUMM_MEMORY 28

#define EXT_MEMORY 36

#define ASBR_MEMORY 28

/* calc for Router Link State = (header + (link_size * #of links))* No fo routers */

RLS = (RLS_HEADER + (RL_SIZE*(three/one+1))) * one;

/* 1 is added because three/one rounds down */

/* calc for Network Links State = (NLS_header + (No fo routers on each seg * 4 bytes))* no multi acces net */

NLS = (NLS_HEADER + (four_2*SIZE_ROUTER)) * four_1;

/* calc for summary link state = header * three */

SLS = SUMM_MEMORY * three;

/* calc for external link states = header * five */

ELS = EXT_MEMORY * five ;

/* calc for ASBR LS = header (assuming one ASBR) */

ASBR = ASBR_MEMORY;

RLS---Router Link State

NLS---Network Link State

SLS---Summary Link State

ELS---External Link State.

ASBR--Autonomous System Border Router.

The folowing RFC will give u a detailed info on this:

http://www.cse.ohio-state.edu/cgi-bin/rfc/rfc1247.html

View solution in original post

3 Replies 3

smahbub
Level 6
Level 6

With show ip ospf database database-summary you get the type and number of routes you have and with the formulas below you can figure out the size you are occupying with the LSAs OSPF Memory Calculation All fields in the LSA's were calculated from what RFC 1247 states. Following constants were used

#define RLS_HEADER 24

#define RL_SIZE 12

#define NLS_HEADER 24

#define SIZE_ROUTER 4

#define SUMM_MEMORY 28

#define EXT_MEMORY 36

#define ASBR_MEMORY 28

/* calc for Router Link State = (header + (link_size * #of links))* No fo routers */

RLS = (RLS_HEADER + (RL_SIZE*(three/one+1))) * one;

/* 1 is added because three/one rounds down */

/* calc for Network Links State = (NLS_header + (No fo routers on each seg * 4 bytes))* no multi acces net */

NLS = (NLS_HEADER + (four_2*SIZE_ROUTER)) * four_1;

/* calc for summary link state = header * three */

SLS = SUMM_MEMORY * three;

/* calc for external link states = header * five */

ELS = EXT_MEMORY * five ;

/* calc for ASBR LS = header (assuming one ASBR) */

ASBR = ASBR_MEMORY;

RLS---Router Link State

NLS---Network Link State

SLS---Summary Link State

ELS---External Link State.

ASBR--Autonomous System Border Router.

The folowing RFC will give u a detailed info on this:

http://www.cse.ohio-state.edu/cgi-bin/rfc/rfc1247.html

Hi

in my network lsdb size is 45000. LDP is running over it . how can i reduce my lsdb size in ospf 

You use techniques like stub areas and/or ABR address range and/or redistribution filters on ASBRs.

Review Cisco Networking for a $25 gift card