The import-route command imports other routing protocol routes to RIP.
The undo import-route command deletes other routing protocol routes from RIP.
By default, RIP does not import routes from any other processes or routing protocols.
import-route { { static | direct | bgp | unr } | { { rip | ospf | isis } [ process-id ] } } [ [ cost cost ] | [ route-filter route-filter-name | route-policy route-policy-name ] ] *
import-route bgp { cost transparent { route-filter route-filter-name | route-policy route-policy-name } | route-policy route-policy-name cost transparent | route-filter route-filter-name cost transparent | cost transparent }
undo import-route { { direct | static | bgp | unr } | { { ospf | rip | isis } [ process-id ] } }
Parameter | Description | Value |
---|---|---|
static |
Imports static routes. |
- |
direct |
Imports direct routes. |
- |
bgp |
Imports BGP routes. |
- |
unr |
Imports UNR routes. |
- |
rip |
Imports RIP routes. |
- |
ospf |
Imports OSPF routes. |
- |
isis |
Imports IS-IS routes. |
- |
process-id |
Specifies the ID of an IS-IS, OSPF, or RIP process. A device can import RIP routes from other processes with an ID different from the local one. |
The value is an integer ranging from 1 to 4294967295. The default value is 1. |
cost cost |
Specifies the cost for imported routes. |
The value is an integer ranging from 0 to 15. The default value is 0. |
route-filter route-filter-name |
Specifies the name of a route-filter used to filter imported routes. A device imports only routes matching the policy. |
The value is a string of 1 to 200 case-sensitive characters, spaces not supported. If parameters are included in the referenced route-filter, specify values for them in the format of (var1, var2, ...var8) behind the route-filter name. A maximum of eight parameters can be specified, and each value ranges from 1 to 200 characters. |
route-policy route-policy-name |
Specifies the name of a route-policy used to filter imported routes. A device imports only routes matching the policy. |
The name is a string of 1 to 200 case-sensitive characters, with spaces not supported. When double quotation marks are used around the string, spaces are allowed in the string. |
transparent |
Retains the Multi_Exit Discriminator (MED) value of an imported BGP route as its cost. transparent takes effect only when the protocol is BGP. |
- |
Usage Scenario
When RIP and other routing protocols are deployed on a network, you can enable the traffic within a RIP domain to reach a destination outside the RIP domain using the import-route command.
Prerequisites
A RIP process has been created and the RIP view has been displayed using the rip command.
Configuration Impact
Importing routes from other routing protocols to a RIP process can lead to routing loops. Therefore, exercise caution when running this command.
Precautions
The import-route command cannot import default routes.
<HUAWEI> system-view [~HUAWEI] rip 1 [*HUAWEI-rip-1] import-route static route-filter filter1(10,11,12,13,14,15,16,17)
<HUAWEI> system-view [~HUAWEI] rip 1 [*HUAWEI-rip-1] import-route isis 7 cost 5