R3303-HP HSR6800 Routers Layer 3 - IP Routing Command Reference

106
Parameters
protocol: Redistributes routes from the specified protocol, which can be bgp, direct, isis, ospf, rip, or
static.
process-id: Specifies a process by its ID in the range of 1 to 65535. The default is 1. It is available only
when the protocol is rip, ospf, or isis.
all-processes: Redistributes routes from all the processes of the specified routing protocol. This keyword
takes effect only when the protocol is rip, ospf, or isis.
allow-ibgp: Allows IBGP routes redistribution. It is optional only when the protocol is bgp.
cost cost: Specifies a route cost in the range of 0 to 16777214. The default is 1.
type type: Specifies a cost type, 1 or 2. The default is 2.
tag tag: Specifies a tag for external LSAs. The default is 1.
route-policy route-policy-name: Specifies a routing policy to redistribute qualified routes only. A routing
policy name is a string of up to 63 case-sensitive characters.
Usage guidelines
OSPF prioritize routes into the following levels:
Intra-area route
Inter-area route
Type-1 external route
Type-2 external route
An intra-area route is a route in an OSPF area. An inter-area route is between any two OSPF areas. Both
of them are internal routes.
An external route is a route to a destination outside the OSPF AS.
A Type-1 external route refers to an IGP route, such as RIP route or static route, and has high reliability.
Its cost is comparable with the cost of OSPF internal routes. The cost from an OSPF router to a Type-1
external route's destination equals the cost from the router to the ASBR plus the cost from the ASBR to the
external route's destination.
A Type-2 external route refers to an EGP route and has low credibility, so OSPF considers the cost from
the ASBR to a Type-2 external route is much bigger than the cost from the ASBR to an OSPF internal router.
The cost from an internal router to a Type-2 external route's destination equals the cost from the ASBR to
the Type-2 external route's destination.
The import-route command cannot redistribute default routes.
Use the import-route bgp allow-ibgp command with care, because it redistributes both EBGP and IBGP
routes that might cause routing loops.
Only active routes can be redistributed. Use the display ip routing-table protocol command to display
route state information.
Examples
# Redistribute routes from RIP process 40 and specify the type, tag, and cost as 2, 33 and 50 for
redistributed routes.
<Sysname> system-view
[Sysname] ospf 100
[Sysname-ospf-100] import-route rip 40 type 2 tag 33 cost 50