OcNOS SP : Layer 3 Guide : Fundamental Layer 3 Command Reference : Route-Map Commands
Route-Map Commands
This chapter describes route-map commands.
continue
The continue clause provides the capability to execute additional entries in a route map after an entry is executed with a successful match and set clauses (i.e), the continue command allows multiple entries to be evaluated within a single route-map. Continue commands can be assigned optional sequence numbers that indicate the order in which clauses are to be evaluated.
Use the no form of the command (specifying a particular sequence number if desired), to remove individual or all continue clauses from a route-map.
Continue clause with match Clauses
When a match clause exists in a route map with continue clause, then the continue clause is executed only when a successful match occurs. If a match clause does not exist in the route-map and if a continue clause does exist, the continue clause will be evaluated and then go to the specified route-map entry. When a successful match occurs and we have a continue clause, the route-map executes the set clauses and then goes to the specified route-map entry. If continue clause does not exist in the next route map, then the route-map will behave normally. If a continue clause exists in the next route-map but a match is not successful, the route-map will not continue and will fall through to the next sequence number if one exists.
Continue clause with set Clauses
Set clauses are executed after the route-map evaluation is done. The set clauses are evaluated and executed in the order in which they were configured. Set clauses are only executed after a successful match occurs. The continue statement proceeds to the specified route-map entry only after configured set actions are performed. If a set action is configured in the first route-map and then the same set action occurs again, but with a different value in a subsequent route-map entry, then the last set action will override the previous set actions, which were configured with the same set command.
Command Syntax
continue <2-65535>|)
no continue <2-65535>|)
Parameter
<2-65535>
Continue sequence number.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
(config)#route-map Rmap1
(config-route-map)#continue ?
<2-65535> Route-map entry sequence number
<cr>
(config-route-map)#continue 10
(config-route-map)#continue 30
 
match as-path
Use this command to match an autonomous system path access list. This command specifies the autonomous system path to be matched. If there is a match for the specified AS path, and permit is specified, the route is redistributed or controlled, as specified by the set action. If the match criteria are met, and deny is specified, the route is not redistributed or controlled. If the match criteria are not met then the route is neither accepted nor forwarded, irrespective of permit or deny specifications.
The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes, depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Note: This command is valid only for BGP.
Use the no parameter with this command to remove a path list entry.
Command Syntax
match as-path WORD
no match as-path (WORD|)
Parameter
WORD
Autonomous system path access list name.
Default
Enabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map myroute deny 34
(config-route-map)#match as-path myaccesslist
match community
Use this command to specify the community to be matched.
Communities are used to group and filter routes. They are designed to provide the ability to apply policies to large numbers of routes by using match and set commands. Community lists are used to identify and filter routes by their common attributes. This command allows the matching based on community lists.
The values set by the match community command overrides the global values. The route that does not match at least one match clause is ignored.
Note: This command is valid only for BGP.
Use the no parameter with this command to remove the community list entry.
Command Syntax
match community (<1-99>|<100-199>|WORD) (exact-match|)
no match community (<1-99>|<100-199>|WORD|) (exact-match|)
Parameters
<1-99>
Community-list number (standard).
<100-199>
Community-list number (expanded).
WORD
Community-list name.
exact-match
Do exact matching of communities.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map myroute permit 3
(config-route-map)#match community mylist
match extcommunity
Use this command to match BGP external community list
Communities are used to group and filter routes. They are designed to provide the ability to apply policies to large numbers of routes by using match and set commands. Community lists are used to identify and filter routes by their common attributes. This command allows the matching based on community lists.
The values set by this command overrides the global values. The route that does not match at least one match clause is ignored.
Note: This command is valid only for BGP.
Use the no parameter with this command to remove the community list entry.
Command Syntax
match extcommunity (<1-99>|<100-199>|WORD) (exact-match|)
no match extcommunity (<1-99>|<100-199>|WORD|) (exact-match|)
Parameters
<1-99>
Community-list number (standard).
<100-199>
Community-list number (expanded).
WORD
Name of the community-list.
exact-match
Do exact matching of communities.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map myroute permit 3
(config-route-map)#match extcommunity mylist
match interface
Use this command to define the interface match criterion. This command specifies the next-hop interface name of a route to be matched.
Use the no parameter with this command to remove the specified match criterion.
Command Syntax
match interface IFNAME
no match interface (IFNAME|)
Parameter
IFNAME
Interface name.
Default
By default, match interface is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map mymap1 permit 10
(config-route-map)#match interface eth0
match ip address
Use this command to specify the match address of route. If there is a match for the specified IP address, and permit is specified, the route is redistributed or controlled, as specified by the set action. If the match criteria are met, and deny is specified then the route is not redistributed or controlled. If the match criteria are not met, the route is neither accepted nor forwarded, irrespective of permit or deny specifications.
The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes, depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Use the no parameter with this command to remove the match ip address entry.
Command Syntax
match ip address (<1-199>|<1300-2699>|WORD)
no match ip address (<1-199>|<1300-2699>|WORD|)
Parameters
WORD
IP access-list name.
<1-199>
IP access-list number (standard range).
<1300-2699>
IP access-list number (expanded range).
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map myroute permit 3
(config-route-map)#match ip address List1
match ip address prefix-list
Use this command to match entries of a prefix-list. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Use the no parameter with this command too disable this function
Command Syntax
match ip address prefix-list WORD
no match ip address prefix-list (WORD|)
Parameter
WORD
IP prefix list name.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#match ip address prefix-list mylist
match ip next-hop
Use this command to specify a next-hop address to be matched in a route-map. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Use the no parameter with this command to disable this function.
Command Syntax
match ip next-hop (<1-199>|<1300-2699>|WORD)
no match ip next-hop (<1-199>|<1300-2699>|WORD|)
Parameters
WORD
Specify the IP access-list name.
<1-199>
Specify the IP access-list number (standard range).
<1300-2699>
Specify the IP access-list number (expanded range).
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#match ip next-hop mylist
match ip next-hop prefix-list
Use this command to specify the next-hop IP address match criterion using the prefix-list. This command matches the next-hop IP address of a route.
Use the no parameter with this command to remove the specified match criterion.
Command Syntax
match ip next-hop prefix-list WORD
no match ip next-hop prefix-list (WORD|)
Parameter
WORD
Prefix-list name.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map mymap permit 3
(config-route-map)#match ip next-hop prefix-list list1
match ip peer
Use this command to specify the match peer IPv4 address of a route.
Use the no parameter with this command to remove the specified match criterion.
Command Syntax
match ip peer (<1-199>|<1300-2699>|WORD)
no match ip peer (<1-199>|<1300-2699>|WORD|)
Parameter
WORD
IP access-list name.
<1-199>
IP access-list number (standard range).
<1300-2699>
IP access-list number (expanded range).
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map mymap permit 3
(config-route-map)#match ip peer 123
 
(config-route-map)#no match ip peer 123
match ipv6 address
Use this command to specify the match address of route. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Use the no parameter with this command to remove the match ip address entry.
Note: This command is valid for BGP, OSPFv3, and RIPng only.
Command Syntax
match ipv6 address WORD
no match ipv6 address (WORD|)
Parameter
WORD
IPv6 access list name.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map myRM deny 1
(config-route-map)#match ipv6 address myRM
match ipv6 address prefix-list
Use this command to match entries of a prefix-list. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes, depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Note: This command is valid for BGP, OSPFv3, and RIPng only.
Use the no parameter with this command to disable this function
Command Syntax
match ipv6 address prefix-list WORD
no match ipv6 address prefix-list (WORD|)
Parameter
WORD
IPv6 access list name.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#match ipv6 address prefix-list mylist
match ipv6 next-hop
Use this command to specify the next-hop address to be matched. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Note: This command is valid for BGP and IS-IS only.
Use the no parameter with this command to disable this function
Command Syntax
match ipv6 next-hop (X:X::X:X|WORD)
no match ipv6 next-hop (X:X::X:X|WORD|)
Parameters
X:X::X:X
IPv6 address of the next-hop.
WORD
IPv6 access list name.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#match ipv6 next-hop 3ffe::1
match ipv6 next-hop prefix-list
Use this command to match entries of a prefix-list. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Note: This command is valid for BGP and IS-IS only.
Use the no parameter with this command to disable this function
Command Syntax
match ipv6 next-hop prefix-list WORD
no match ipv6 next-hop prefix-list WORD
Parameters
WORD
IPv6 access list name.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#match ipv6 next-hop prefix-list new
match ipv6 peer
Use this command to specify the match peer IPv6 address of a route.
Use the no parameter with this command to remove the specified match criterion.
Command Syntax
match ipv6 peer (<1-199>|<1300-2699>|WORD)
no match ipv6 peer (<1-199>|<1300-2699>|WORD|)
Parameter
WORD
IP access-list name.
<1-199>
IP access-list number (standard range).
<1300-2699>
IP access-list number (expanded range).
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map mymap permit 3
(config-route-map)#match ipv6 peer 123
 
(config-route-map)#no match ipv6 peer 123
 
match metric
Use this command to match a metric of a route. The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Note: This command is valid for BGP, OSPF, RIP, and IS-IS only.
Use the no parameter with this command to disable this function
Command Syntax
match metric <0-4294967295>
no match metric (<0-4294967295>|)
Parameters
<0-4261412864>
Metric value.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map myroute permit 3
(config-route-map)#match metric 888999
match origin
Use this command to match origin code. The origin attribute defines the origin of the path information. The egp parameter is indicated as an e in the routing table, and it indicates that the origin of the information is learned via EGP (Exterior Gateway Protocol). The igp parameter is indicated as an i in the routing table, and it indicates the origin of the path information is interior to the originating AS. The incomplete parameter is indicated as a ? in the routing table, and indicates that the origin of the path information is unknown or learned through other means. If a static route is redistributed into BGP, the origin of the route is incomplete.
This command specifies the origin to be matched. If there is a match for the specified origin, and permit is specified when you created the route-map, the route is redistributed or controlled as specified by the set action. If the match criteria are met, and deny is specified, the route is not redistributed or controlled. If the match criteria are not met, the route is neither accepted nor forwarded, irrespective of permit or deny specifications.
The route specified by the policies might not be the same as specified by the routing protocols. Setting policies enable packets to take different routes depending on their length or content. Packet forwarding based on configured policies overrides packet forwarding specified in routing tables.
Note: This command is valid only for BGP.
Use the no parameter with this command to disable this matching.
Command Syntax
match origin (egp|igp|incomplete)
no match origin (egp|igp|incomplete|)
Parameters
egp
Remote exterior gateway protocol.
igp
Local internal gateway protocol.
incomplete
Unknown heritage.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map myroute deny 34
(config-route-map)#match origin egp
match route-type
Use this command to match an external route type. AS-external LSA is either Type-1 or Type-2. External type-1 matches only Type 1 external routes and external type-2 matches only Type 2 external routes.
Use the no parameter with this command to turn off the matching.
Command Syntax
match route-type external (type-1|type-2)
no match route-type external (type-1|type-2|)
Parameters
type-1
Match OSPF External Type 1 metric.
type-2
Match OSPF External Type 2 metric.
Default
By default, match route type external is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map mymap1 permit 10
(config-route-map)#match route-type external type-1
match tag
Use this command to match the specified tag value.
Use the no parameter with this command to turn off the declaration.
Command Syntax
match tag <0-4294967295>
no match tag (<0-4294967295>|)
Parameters
<0-4294967295>
Tag value.
Default
By default, match tag is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map mymap1 permit 10
(config-route-map)#match tag 100
route-map
Use this command to enter route-map mode and to permit or deny match/set operations.
This command controls and modifies routing information to allow redistribution of routes. It has a list of match and set commands associated with it. The match commands specify the conditions under which redistribution is allowed, and the set commands specify the particular redistribution actions to be performed if the criteria enforced by match commands are met. Route maps are used for detailed control over route distribution between routing processes.
Route maps also allow policy routing, and might route packets to a different route than the obvious shortest path.
Use the no parameter with this command to turn off the declaration.
Command Syntax
route-map WORD (deny|permit) <1-65535>
no route-map WORD ((deny|permit) <1-65535>|)
Parameters
WORD
Route-map name (maximum size 63 characters).
deny
Route map deny set operations. If this parameter is specified, and the match criteria are met, the route is not redistributed, and any other route maps with the same map tag are not examined.
permit
Route map permit set operations. If this parameter is specified, and the match criteria are met, the route is redistributed as specified by the set actions. If the match criteria are not met, the next route map with the same tag is tested.
<1-65535>
Sequence to insert into or delete from an existing route-map.
Default
No default value is specified
Command Mode
Configure mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map route1 permit 1
(config-route-map)#
set aggregator
Use this command to set the AS number for the route map and router ID. An Autonomous System (AS) is a collection of networks under a common administration sharing a common routing strategy. It is subdivided by areas, and is assigned a unique 16-bit number. Use the set aggregator command to assign an AS number for the aggregator.
To use the set aggregator command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to disable this function
Command Syntax
set aggregator as <1-65535> A.B.C.D
no set aggregator as (<1-65535> A.B.C.D|)
Parameters
<1-65535>
AS number of aggregator.
A.B.C.D
IP address of aggregator.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map myroute permit 3
(config-route-map)#set aggregator as 43 10.10.0.3
set as-path
Use this command to modify an autonomous system path for a route. By specifying the length of the AS-Path, the router influences the best path selection by a neighbor. Use this command to prepend an AS path string to routes increasing the AS path length.
To use this command, you must first give the match and set commands configure the conditions for redistributing routes from one routing protocol to another:
The match command specifies the match criteria under which redistribution is allowed for the current route-map.
The set command specifies the set redistribution actions to be performed if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to disable this function.
Command Syntax
set as-path prepend .<1-65535>
set as-path prepend .<1-4294967295>
no set as-path prepend (.<1-65535>|)
no set as-path prepend (.<1-4294967295>|)
Parameters
<1-65535>
OcNOS prepends this number to the AS path.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map myroute permit 3
(config-route-map)#set as-path prepend 8 24
set atomic-aggregate
Use this command to set an atomic aggregate attribute.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to disable this function
Command Syntax
set atomic-aggregate
no set atomic-aggregate
Parameters
No default value is specified
Default
None
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set atomic-aggregate
set comm-list
Use this command to delete the matched communities from the community attribute of an inbound or outbound update when applying route-map.
Use the no parameter with this command to disable this feature.
Command Syntax
set comm-list (<1-99>|<100-199>|WORD) delete
no set comm-list (<1-99>|<100-199>|WORD) delete
Parameters
<1-99>
Standard community-list number.
<100-199>
Expanded community-list number.
WORD
Name of the community-list.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map myRM permit 3
(config-route-map)#set comm-list 34 delete
set community
Use this command to set the communities attribute. and group destinations in a certain community, as well as apply routing decisions according to those communities.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to delete the entry.
Command Syntax
set community [<65536-4294901759>|AA:NN|internet|local-AS|no-advertise|no-export|none] (additive|)
no set community [AA:NN|internet|local-AS|no-advertise|no-export|none] (additive|)
Parameters
<65536-4294901759>
Community number
AA:NN
The community number in aa:nn format.
internet
Internet.
local-AS
Do not send outside the local AS (well-known community).
no-advertise
Do not advertise this route to eBGP peers
no-export
Do not advertise this route to any peer.
none
Remove the community attribute from the prefixes that pass the route-map.
additive
Add to the existing community.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
The following examples show the use of the set community command with different parameters.
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set community no-export no-advertise
 
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set community no-advertise
 
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set community 10:01 23:34 12:14 no-export
set dampening
Use this command to enable route-flap dampening and set parameters. Set the unreachability half-life time to be equal to, or greater than, reachability half-life time. The suppress-limit value must be greater than or equal to the reuse limit value.
Use the no parameter with this command to delete the entry.
Command Syntax
set dampening <1-45> <1-20000> <1-20000> <1-255> (<1-45>|)
no set dampening <1-45> <1-20000> <1-20000> <1-255> (<1-45>|)
Parameters
<1-45>
Reachability half-life time in minutes. The time for the penalty to decrease to one-half of its current value.
<1-20000>
Reuse-limit value. When the penalty for a suppressed route decays below the reuse value, the routes become unsuppressed.
<1-20000>
Suppress-limit value. When the penalty for a route exceeds the suppress value, the route is suppressed.
<1-255>
Max-suppress-time. Maximum time that a dampened route is suppressed.
<1-45>
Unreachability half-life time for penalty, in minutes.
Default
Default reachability half-life time: 15 minutes
Default reuse limit value: 750
Default suppress limit value: 2000
Default max-suppress value is 4 times the half-life time (60 minutes)
Default unreachability half-life time value: 15 minutes
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map R1 permit 24
(config-route-map)#set dampening 20 333 534 30
set extcommunity
Use this command to set an extended community attribute.
To use this command you must first have a match clause. The match and set commands define the conditions for redistributing routes from one routing protocol to another:
The match command defines the match criteria under which redistribution is allowed for the current route-map.
The set command defines the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to disable this function.
Command Syntax
set extcommunity rt .AA:NN (additive|)
set extcommunity soo .AA:NN
set extcommunity cost (igp|pre-bestpath|) <0-255> <0-4294967295>
set extcommunity color <1-4294967295>
no set extcommunity rt (.AA:NN|) (additive|)
no set extcommunity soo (.AA:NN|)
no set extcommunity cost (igp|pre-bestpath|) <0-255> <0-4294967295>
no set extcommunity color <1-4294967295>
Parameters
rt
Route target extended community.
.AA:NN
VPN extended community
additive
Add to the exsisting community.
soo
Site-of-origin extended community.
cost
Extended cost community.
igp
Compare following IGP cost comparison.
pre-bestpath
 
Compare following IGP cost comparison.
<0-255>
Community ID.
<0-4294967295>
 
Cost.
color
Color value extended community
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set extcommunity rt 06:01
 
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set extcommunity rt 0.0.0.6:01
 
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set extcommunity soo 06:01
 
#configure terminal
(config-route-map)#route-map rmap1 permit 3
(config-route-map)#set extcommunity soo 0.0.0.6:01
 
#configure terminal
(config-route-map)#route-map rmap1 permit 3
(config-route-map)#set extcommunity color 101
set interface null0
Use this command to discard routes based on policy/rules configured for a route map.
Route maps can be applied to BGP neighbors. When this command is given for a route map and that route map is applied to a BGP neighbor, the discard route entries are added by BGP for the prefix permitted by the route map.
Use the no form of this command to not discard routes based on policy/rules configured for a route map.
Command Syntax
set interface null0
no set interface null0
Parameters
None
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
To discard 1.1.1.1/24 from BGP neighbor 30.1.1.1:
#configure terminal
(config)#ip prefix-list myPrefixList seq 5 permit 1.1.1.1/24 eq 24
(config)#route-map myRM permit 1
(config-route-map)#match ip address prefix-list myPrefixList
(config-route-map)#set interface null0
(config-route-map)#exit
(config)#router bgp 200
(config-router)#neighbor 30.1.1.1 remote-as 200
(config-router)#neighbor 30.1.1.1 route-map myRM in
set ip next-hop
Use this command to set the specified next-hop value.
Use the no parameter with this command to turn off the setting.
Note: This command is valid for BGP, OSPF, and RIP only.
Command Syntax
set ip next-hop A.B.C.D
no set ip next-hop (A.B.C.D|)
Parameter
A.B.C.D
IP address of the next-hop.
Default
By default, set ip next hop A.B.C.D is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map mymap permit 3
(config-route-map)#set ip next-hop 10.10.0.67
set ipv6 next-hop
Use this command to set a next hop-address.
Use the no parameter with this command to delete an entry.
Note: This command is valid for BGP and OSPFv3 only.
Command Syntax
set ipv6 next-hop X:X::X:X
set ipv6 next-hop local X:X::X:X
no set ipv6 next-hop (X:X::X:X|)
no set ipv6 next-hop local (X:X::X:X|)
Parameters
X:X::X:X
Global IPv6 address of the nexthop.
local
Local IPv6 address of the nexthop.
Default
By default, set ipv6 next hop X:X::X:X is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set ipv6 next-hop local fe80::203:47ff:fe97:66dc
set level
Use this command to set the IS-IS level to export a route.
Use the no parameter with this command to disable this function.
Command Syntax
set level (level-1|level-2|level-1-2)
no set level (level-1|level-2|level-1-2|)
Parameters
level-1
Export into a level-1 area.
level-2
Export into a level-2 sub-domain.
level-1-2
Export into level-1 and level-2.
Default
By default, set level is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set level level-1
set local-preference
Use this command to set the BGP local preference path attribute.
Use the no parameter with this command to disable this function.
Command Syntax
set local-preference <0-4294967295>
no set local-preference (<0-4294967295>|)
Parameters
<0-4294967295>
Tag value for destination routing protocol.
Default
By default, set local preference is disabled
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set local-preference 12
set metric
Use this command to set a metric value for a route and influence external neighbors about the preferred path into an Autonomous System (AS). The preferred path is the one with a lower metric value. A router compares metrics for paths from neighbors in the same ASs. To compare metrics from neighbors coming from different ASs, use the bgp always-compare-med command.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to disable this function.
Command Syntax
set metric WORD
no set metric (WORD|)
Parameters
WORD
Metric value [+/-] <1-4294967295>
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set metric 600
set metric-type
Use this command to set the metric type for the destination routing protocol. Select a type to be either Type-1 or Type-2 in the AS-external-LSA when the route-map matches the condition.
Note: This command is for OSPF, OSPFv3, or IS-IS only.
Use the no parameter with this command to return to the default.
Command Syntax
set metric-type (internal|external)
set metric-type (type-1|type-2)
no set metric-type (internal|external|)
no set metric-type (type-1|type-2|)
Parameters
external
IS-IS external metric type.
internal
IS-IS internal metric type.
type-1
OSPF external type 1 metric.
type-2
OSPF external type 2 metric
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
In this example the metric type of the destination protocol is set to OSPF external Type 1.
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set metric-type type-1
set origin
Use this command to set the BGP origin code. The origin attribute defines the origin of the path information.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to delete an entry.
Command Syntax
set origin (egp|igp|incomplete)
no set origin (egp|igp|incomplete|)
Parameters
egp
Learned through an Exterior Gateway Protocol.
igp
Interior to the originating AS. This happens when an Internal Gateway Protocol is redistributed into BGP.
incomplete
Unknown or learned through some other means. This happens when a static route is redistributed in BGP and the origin of the route is incomplete.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set origin egp
set originator-id
Use this command to set the originator ID attribute.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Use the no parameter with this command to disable this function
Command Syntax
set originator-id A.B.C.D
no set originator-id (A.B.C.D|)
Parameter
A.B.C.D
IP address of originator.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set originator-id 1.1.1.1
set tag
Use this command to set a tag value. The parameter is the route tag that is labeled by another routing protocol (BGP or other IGP when redistributing), because AS-external-LSA has a route-tag field in its LSAs. In addition, when using route-map, OcNOS can tag the LSAs with the appropriate tag value. Sometimes the tag matches with using route-map, and sometimes, the value may be used by another application.
Use the no parameter with this command to unset a tag value.
Command Syntax
set tag <0-4294967295>
no set tag (<0-4294967295>|)
Parameter
<0-4294967295>
Tag value for destination routing protocol.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
In the following example the tag value of the destination routing protocol is set to 6:
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set tag 6
set vpnv4 next-hop
Use this command to set a VPNv4 next-hop address.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
If the packets do not match any of the defined criteria, they are routed through the normal routing process.
Note: This command is valid for BGP only.
Use the no parameter with this command to disable this function
Command Syntax
set vpnv4 next-hop A.B.C.D
no set vpnv4 next-hop (A.B.C.D|)
Parameter
A.B.C.D
IP address of originator.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#set vpnv4 next-hop 6.6.6.6
set weight
Use this command to set weights for the routing table.
The weight value is used to assist in best path selection. It is assigned locally to a router. When there are several routes with a common destination, the routes with a higher weight value are preferred.
To use this command, you must first have a match clause. Match and set commands set the conditions for redistributing routes from one routing protocol to another. The match command specifies the match criteria under which redistribution is allowed for the current route-map. The set command specifies the set redistribution actions to be performed, if the match criteria are met.
Note: This command is valid only for BGP.
Use the no parameter with this command to delete an entry.
Command Syntax
set weight <0-4294967295>
no set weight (<0-4294967295>|)
Parameter
<0-4294967295>
Weight value.
Default
No default value is specified
Command Mode
Route-map mode
Applicability
This command was introduced before OcNOS version 1.3.
Examples
In the following configuration, all routes that apply to access-list 10 will have the weight set at 400. If the packets do not match any of the defined criteria, they are routed through the normal routing process.
#configure terminal
(config)#route-map rmap1 permit 3
(config-route-map)#match as-path 10
(config-route-map)#set weight 400
show route-map
Use this command to display route-map information.
Command Syntax
show route-map (|WORD)
Parameters
WORD
Route-map name (maximum size 63 characters)
Command Mode
Exec mode and Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
The following is a sample output of the show route-map command.
#show route-map
route-map myRM, permit, sequence 1
Match clauses:
metric 200
Set clauses:
metric 60
#
Table 2-4 explains the output fields.
 
Table 2-4: show route-map details
Field
Description
route-map
Name of a route map.
permit
Routes that match the match clauses are redistributed according to the conditions defined by the set clauses.
sequence
Position of this route map in sequence of route-maps with the same name.
Match clauses
Routes that match the conditions defined by the match clause are redistributed according to the conditions defined by the set clauses.
Set clauses
Routes that pass the match clause are redistributed according to the conditions defined by the set clauses.
 
show running-config route-map
Use this command to display the running system status and configuration details for route-maps.
Command Syntax
show running-config route-map
Parameters
None
Command Mode
Privileged Exec mode
Applicability
This command was introduced before OcNOS version 1.3.
Example
>enable
#show running-config route-map
!
route-map abc deny 2
match community 2
!
route-map abc permit 3
match route-type external type-2
set metric-type type-1
!