Configuring a Dynamic Routing Protocol to Import Direct Routes

After you associate direct routes with a Virtual Router Redundancy Protocol (VRRP) group, configure a dynamic routing protocol to import the direct routes so that the path selection by the dynamic routing protocol can be controlled.

Context

After direct routes are associated with a VRRP group, VRRP-enabled devices modify the cost of each direct route to the virtual IP network segment based on the VRRP status. To control the path by a dynamic routing protocol, enable the dynamic routing protocol to import direct routes and inherit the costs from the imported direct routes.

Currently, dynamic routing protocols include the Interior Gateway Protocol (IGP) and Border Gateway Protocol (BGP). If an IGP is configured to import direct routes, routing information protocol (RIP) cannot inherit costs from the imported direct routes. This section describes how to configure Open Shortest Path First (OSPF), Intermediate System to Intermediate System (IS-IS), and BGP to import direct routes.

Procedure

  • Configure OSPF to import direct routes.
    1. Run system-view

      The system view is displayed.

    2. Run ospf [ process-id ]

      The OSPF process view is displayed.

    3. Run import-route direct

      OSPF is configured to import direct routes.

    4. Run default cost inherit-metric

      OSPF is enabled to inherit the costs from the imported direct routes.

    5. Run commit

      The configuration is committed.

  • Configure IS-IS to import direct routes.
    1. Run system-view

      The system view is displayed.

    2. Run isis [ process-id ]

      The IS-IS process view is displayed.

    3. Run import-route direct inherit-cost

      IS-IS is configured to import direct routes and to inherit the costs from the imported direct routes.

    4. Run commit

      The configuration is committed.

  • Configure BGP to import direct routes.
    1. Run system-view

      The system view is displayed.

    2. Run bgp as-number

      The BGP process view is displayed.

    3. Run import-route direct

      BGP is configured to import direct routes.

      BGP automatically inherits the costs from the imported direct routes. The inherited costs are shown as the multi-exit discrimination (MED) values.

    4. Run commit

      The configuration is committed.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
Next topic >