Send document comments to nexus7k-docfeedback@cisco.com.
6-33
Cisco Nexus 7000 Series NX-OS Unicast Routing Configuration Guide, Release 4.x
OL-20002-02
Chapter 6 Configuring OSPFv2
Configuring Advanced OSPFv2
The following example shows how to redistribute the Border Gateway Protocol (BGP) into OSPF:
switch# config t
switch(config)# router ospf 201
switch(config-router)# redistribute bgp route-map FilterExternalBGP
switch(config-router)# copy running-config startup-config
Limiting the Number of Redistributed Routes
Route redistribution can add many routes to the OSPFv2 route table. You can configure a maximum limit
to the number of routes accepted from external protocols. OSPFv2 provides the following options to
configure redistributed route limits:
• Fixed limit—Log a message when OSPFv2 reaches the maximum the configured maximum.
OSPFv2 does not accept any more redistributed routes. You can optionally configure a threshold
percentage of the maximum where OSPFv2 will log a warning when that threshold is passed.
• Warning only—Log a warning only when OSPFv2 reaches the maximum. OSPFv2 continuse to
accept redistributed routes.
• Widthdraw—Start the timeout period when OSPFv2 reaches the maximum. After the timeout
period, OSPFv2 requests all redistributed routes if the current number of redistributed routes is less
than the maximum limit. If the current number of redistributed routes is at the maximum limit,
OSPFv2 withdraws all redistributed routes. You must clear this condition before OSPFv2 accepts
more redistributed routes.
You can optionally configure the timeout period.
BEFORE YOU BEGIN
Ensure that you have enabled the OSPF feature (see the “Enabling the OSPFv2 Feature” section on
page 6-14).
Ensure that you are in the correct VDC (or use the switchto vdc command).
SUMMARY STEPS
1. config t
2. router ospf instance-tag
3. redistribute {bgp id | direct| eigrp id | isis id | ospf id | rip id | static} route-map map-name
4. redistribute maximum-prefix max [threshold] [warning-only | withdraw [num-retries timeout]]
5. show running-config ospf
Step 5
default-metric
cost
Example:
switch(config-router)# default-metric 25
Sets the cost metric for the redistributed routes. This
does not apply to directly connected routes. Use a
route map to set the default metric for directly
connected routes.
Step 6
copy running-config startup-config
Example:
switch(config-router)# copy
running-config startup-config
(Optional) Saves this configuration change.
Command Purpose