Cisco Systems IOS XR Laptop User Manual


 
Implementing Routing Policy on Cisco IOS XR Software
Information About Implementing Routing Policy
RC-232
Cisco IOS XR Routing Configuration Guide
route-policy OSPF-redist
set metric-type type-2
if tag eq 10 then
set cost 100
elseif tag eq 20 then
set cost 200
else
drop
endif
end-policy
router ospf 1
redistribute isis instance_10 policy OSPF-redist
.
.
.
OSPF Attributes and Operators
Table 5 summarizes the OSPF attributes and operators.
OSPFv3 Policy Attach Points
This section describes each of the OSPFv3 policy attach points and provides a summary of the BGP
attributes and operators.
Default Originate
The default originate attach point allows the user to conditionally inject the default route 0::/0 into the
OSPFv3 link-state database, which is done by evaluating the attached policy. If any routes in the local
RIB pass the policy, then the default route is inserted into the link-state database.
The following example shows how to generate a default route if any of the routes that match 2001::/96
are present in the RIB:
route-policy ospfv3-originate
if rib-has-route in (2001::/96) then
pass
endif
end-policy
Table 5 OSPF Attributes and Operators
Attribute Match Set
cost n/a set
destination in n/a
metric-type n/a set
rib-has-route in n/a
route-type is n/a
tag eq, ge, le set