The apply extcommunity command sets the action for changing the extended community attribute of BGP routes in a routing policy.
The undo apply extcommunity command restores the default setting.
By default, the action for changing the extended community attribute of BGP routes is not set in a routing policy.
Product |
Support |
---|---|
S5720-EI, S5720-HI, S5720I-SI, S5720S-SI, S5720-SI, S5735-S, S5735S-S, S5735-S-I, S5730-HI, S5730S-EI, S5730-SI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-EI, S6720-HI, S6720S-EI, S6720S-SI, S6720-SI, S6730-H, S6730S-H, S6730-S, and S6730S-S |
Supported. |
S2720-EI, S5720-LI, S5735-L, S5735S-L, S5735S-L-M, S5720S-LI, S6720-LI, and S6720S-LI |
Not supported. |
apply extcommunity { rt { as-number:nn | 4as-number:nn | ipv4-address:nn } } &<1-16> [ additive ]
undo apply extcommunity
Parameter | Description | Value |
---|---|---|
rt | Indicates the route-target extended community. A maximum of 16 route targets can be configured. | - |
as-number | Specifies the AS number. | The value is an integer ranging from 0 to 65535. |
4as-number | Specifies a 4-byte AS number. | A 4-byte AS number is divided into the following types:
|
ipv4-address | Specifies the IPv4 address. | It is in dotted decimal notation. |
nn | Specifies an integer. |
|
additive | Indicates that existing community attributes can be added to routes. | - |
Usage Scenario
When controlling inter-AS VPN route receiving and advertising, apply the routing policy that contains the apply extcommunity command to change the RT extended community attribute of matched routes. Currently, only the RT extended community attribute is supported. This command cannot specify an extended community attribute for public routes.
Prerequisites
The apply extcommunity command can be used only after the route-policy command is used.
Precautions
When the routing policy that contains the action is used in the BGP view, BGP IPv4 unicast address view, or BGP IPv6 unicast address view, the action does not take effect.
When a routing policy takes effect, it affects inter-AS VPN route receiving and advertising.
If the keyword additive is not set in the apply extcommunity command, the original extended community attribute is replaced.