Wednesday 11 March 2015

Advanced Ospf Configuration (Cont.) and Verification

Configuring Route Calculation Timers

You can configure the delay time between when OSPF receives a topology change and when it starts an SPF calculation. You also can configure the hold time between two consecutive SPF calculations.
To configure route calculation timers, perform the following steps:

Detailed Steps

 
Command
Purpose
Step 1 

router ospf process_id



Example:

hostname(config)# router ospf 2
This creates an OSPF routing process, and the user enters router configuration mode for this OSPF process.
The process_id is an internally used identifier for this routing process. It can be any positive integer. This ID does not have to match the ID on any other device; it is for internal use only. You can use a maximum of two processes.
Step 2 

timers spf spf-delay spf-holdtime


Example:

hostname(config-router)# timers spf 10 120
This step configure the route calculation times.
The spf-delay is the delay time (in seconds) between when OSPF receives a topology change and when it starts an SPF calculation. It can be an integer from 0 to 65535. The default time is 5 seconds. A value of 0 means that there is no delay; that is, the SPF calculation is started immediately.
The spf-holdtime is the minimum time (in seconds) between two consecutive SPF calculations. It can be an integer from 0 to 65535. The default time is 10 seconds. A value of 0 means that there is no delay; that is, two SPF calculations can be done, one immediately after the other.

Logging Neighbors Going Up or Down

By default, the system sends a system message when an OSPF neighbor goes up or down.
Configure this command if you want to know about OSPF neighbors going up or down without turning on the debug ospf adjacency command. The log-adj-changes router configuration command provides a higher level view of the peer relationship with less output. Configure log-adj-changes detail if you want to see messages for each state change.
To log neighbors going up or down, perform the following steps:

Detailed Steps

 
Command
Purpose
Step 1 

router ospf process_id


Example:

hostname(config)# router ospf 2
This creates an OSPF routing process, and the user enters router configuration mode for this OSPF process.
The process_id is an internally used identifier for this routing process. It can be any positive integer. This ID does not have to match the ID on any other device; it is for internal use only. You can use a maximum of two processes.
Step 2 

log-adj-changes [detail]


Example:

hostname(config-router)# log-adj-changes 
[detail]
This step configures logging for neighbors going up or down.


Monitoring OSPF

You can display specific statistics such as the contents of IP routing tables, caches, and databases. You can also use the information provided to determine resource utilization and solve network problems. You can also display information about node reachability and discover the routing path that your device packets are taking through the network.
To monitor or display various OSPF routing statistics, perform one of the following tasks:
Command
Purpose

show ospf [process-id [area-id]]
Displays general information about OSPF routing processes.

show ospf border-routers
Displays the internal OSPF routing table entries to the ABR and ASBR.



show ospf [process-id [area-id]] database
Displays lists of information related to the OSPF database for a specific router.



show ospf flood-list if-name
Displays a list of LSAs waiting to be flooded over an interface (to observe OSPF packet pacing).
OSPF update packets are automatically paced so they are not sent less than 33 milliseconds apart. Without pacing, some update packets could get lost in situations where the link is slow, a neighbor could not receive the updates quickly enough, or the router could run out of buffer space. For example, without pacing packets might be dropped if either of the following topologies exist:
A fast router is connected to a slower router over a point-to-point link.
During flooding, several neighbors send updates to a single router at the same time.
Pacing is also used between resends to increase efficiency and minimize lost retransmissions. You also can display the LSAs waiting to be sent out an interface. The benefit of the pacing is that OSPF update and retransmission packets are sent more efficiently.
There are no configuration tasks for this feature; it occurs automatically


show ospf interface [if_name]
Displays OSPF-related interface information.


show ospf neighbor [interface-name
neighbor-id] [detail]
Displays OSPF neighbor information on a per-interface basis.


show ospf request-list neighbor if_name
Displays a list of all LSAs requested by a router.

show ospf retransmission-list neighbor 
if_name
Displays a list of all LSAs waiting to be resent.





show ospf [process-id] summary-address
Displays a list of all summary address redistribution information configured under an OSPF process.


show ospf [process-id] virtual-links
Displays OSPF-related virtual links information.

Configuration Example for OSPF

The following example shows how to enable and configure OSPF with various optional processes:

Step 1 Enable OSPF.
hostname(config)# router ospf 2

hostname(config-router)# network 10.0.0.0 255.0.0.0 area 0


Step 2 Redistribute routes from one OSPF process to another OSPF process (optional):
hostname(config)# route-map 1-to-2 permit

hostname(config-route-map)# match metric 1

hostname(config-route-map)# set metric 5

hostname(config-route-map)# set metric-type type-1

hostname(config-route-map)# router ospf 2

hostname(config-router)# redistribute ospf 1 route-map 1-to-2


Step 3 Configure OSPF interface parameters (optional):
hostname(config)# router ospf 2

hostname(config-router)# network 2.0.0.0 255.0.0.0 area 0

hostname(config-router)# interface inside

hostname(config-interface)# ospf cost 20

hostname(config-interface)# ospf retransmit-interval 15

hostname(config-interface)# ospf transmit-delay 10

hostname(config-interface)# ospf priority 20

hostname(config-interface)# ospf hello-interval 10

hostname(config-interface)# ospf dead-interval 40

hostname(config-interface)# ospf authentication-key cisco

hostname(config-interface)# ospf message-digest-key 1 md5 cisco

hostname(config-interface)# ospf authentication message-digest


Step 4 Configure OSPF area parameters (optional):
hostname(config)# router ospf 2

hostname(config-router)# area 0 authentication

hostname(config-router)# area 0 authentication message-digest

hostname(config-router)# area 17 stub

hostname(config-router)# area 17 default-cost 20


Step 5 Configure the route calculation timers and show the log neighbor up/down messages (optional):

hostname(config-router)# timers spf 10 120

hostname(config-router)# log-adj-changes [detail]


Step 6 Restart the OSPF process .
hostname(config)# clear ospf pid {process | redistribution | countes 
[neighbor [neighbor-interface] [neighbor-id]]}


Step 7 Show the results of your OSPF configuration (optional):
The following is sample output from the show ospf command:
hostname(config)# show ospf


Routing Process "ospf 2" with ID 20.1.89.2 and Domain ID 0.0.0.2

Supports only single TOS(TOS0) routes

Supports opaque LSA

SPF schedule delay 5 secs, Hold time between two SPFs 10 secs

Minimum LSA interval 5 secs. Minimum LSA arrival 1 secs

Number of external LSA 5. Checksum Sum 0x 26da6

Number of opaque AS LSA 0. Checksum Sum 0x     0

Number of DCbitless external and opaque AS LSA 0

Number of DoNotAge external and opaque AS LSA 0

Number of areas in this router is 1. 1 normal 0 stub 0 nssa

External flood list length 0

    Area BACKBONE(0)

        Number of interfaces in this area is 1

        Area has no authentication

        SPF algorithm executed 2 times

        Area ranges are

        Number of LSA 5. Checksum Sum 0x 209a3

        Number of opaque link LSA 0. Checksum Sum 0x     0

        Number of DCbitless LSA 0

        Number of indication LSA 0

        Number of DoNotAge LSA 0


        Flood list length 0

No comments:

Post a Comment