OcNOS-RON-6.3.1 : Layer 3 Guide : Fundamental Layer 3 Command Reference : Route-Map Commands : set community
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
Last modified date: 07-13-2023