No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

CLI-based Configuration Guide - IP Unicast Routing

AR100, AR120, AR150, AR160, AR200, AR1200, AR2200, AR3200, and AR3600 V200R009

Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Configuring OSPF to Import External Routes

Configuring OSPF to Import External Routes

Context

To access a router running a non-OSPF protocol, an OSPF-capable router needs to import routes of the non-OSPF protocol into the OSPF network.

OSPF can ensure loop-free intra-area and inter-area routes; however, OSPF cannot protect external routes against loops. Therefore, when configuring OSPF to import external routes, avoid the loops caused by manual configurations.

Do as follows on the router that functions as the ASBR running OSPF:

Procedure

  • Configuring OSPF to import the routes discovered by other protocols
    1. Run system-view

      The system view is displayed.

    2. Run ospf [ process-id ]

      The OSPF process view is displayed.

    3. Run import-route { limit limit-number | { bgp [ permit-ibgp ] | direct | unr | rip [ process-id-rip ] | static | isis [ process-id-isis ] | ospf [ process-id-ospf ] } [ cost cost | type type | tag tag | route-policy route-policy-name ] * }

      The routes discovered by other protocols are imported.

  • Setting parameters for OSPF to import routes
    1. Run system-view

      The system view is displayed.

    2. Run ospf [ process-id ]

      The OSPF process view is displayed.

    3. Run default { cost { cost-value | inherit-metric } | limit limit | tag tag | type type } *

      The default values of parameters (the metric of routes, tag, and type) are set for importing routes.

      The default values of parameters (the cost, number of routes, tag, and type) are set for imported routes.

      When OSPF imports external routes, you can set default values for some additional parameters, such as the cost, number of routes to be imported, route tag, and route type. The route tag is used to identify the protocol-related information. For example, it can be used to differentiate AS numbers carried in BGP routes imported by OSPF.

      By default, the cost of the external routes imported by OSPF is 1; the type of the imported external routes is Type 2; the default tag value of the imported routes is 1.

      NOTE:
      You can run one of the following commands to set the cost of the imported route. The following commands are listed in descending order of priority.
      • Run the apply cost command to set the cost of a route.
      • Run the import-route command to set the cost of the imported route.
      • Run the default command to set the default cost of the imported route.

Translation
Download
Updated: 2019-05-17

Document ID: EDOC1000174069

Views: 130331

Downloads: 274

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next