Route policy action commands

action

Syntax

action {accept | next-entry | next-policy | reject}

no action

Context

config>router>policy-options>policy-statement>entry

Platforms

Supported on all 7210 SAS platforms as described in this document, including platforms configured in the access-uplink operating mode

Description

Commands in this context configure actions to take for routes matching a route policy statement entry.

This command is required and must be entered for the entry to be active.

Any route policy entry without the action command is considered incomplete and inactive.

The no form of this command deletes the action context from the entry.

Default

no action

Parameters

accept

Keyword to specify routes matching the entry match criteria is accepted and propagated.

next-entry

Keyword to specify that the actions specified would be made to the route attributes and then policy evaluation would continue with next policy entry (if any others are specified).

next-policy

Keyword to specify that the actions specified would be made to the route attributes, and then policy evaluation would continue with next route policy (if any others are specified).

reject

Keyword to specify routes matching the entry match criteria would be rejected.

aigp-metric

Syntax

aigp-metric metric

aigp-metric metric add

aigp-metric igp

no aigp-metric

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

7210 SAS-Mxp, 7210 SAS-R6, and 7210 SAS-R12

Description

The effect of this command on a route matched and accepted by a route policy entry depends on how the policy is applied (BGP import policy versus BGP export policy), the type of route, and the specific form of this command.

In a BGP import policy, this command is used to:

  • associate an AIGP metric with an iBGP route received with an empty AS path and no AIGP attribute

  • associate an AIGP metric with an eBGP route received without an AIGP attribute that has an AS path containing only AS numbers belonging to the local AIGP administrative domain

  • modify the received AIGP metric value before BGP path selection

In a BGP export policy, this command is used to:

  • add the AIGP attribute and set the AIGP metric value in a BGP route originated by exporting a direct, static, or IGP route from the routing table

  • remove the AIGP attribute from a route advertisement to a specific peer

  • modify the AIGP metric value in a route advertisement to a specific peer

The no form of this command removes the AIGP attribute and any explicit AIGP metric value changes that were previously configured using this command.

Default

no aigp-metric

Parameters

add

Keyword to add the AIGP attribute.

igp

Keyword to set the AIGP metric value to the IGP metric value.

metric

Specifies the AIGP metric value.

Values

0 to 4294967295

as-path

Syntax

as-path {add | replace} name

no as-path

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns a BGP AS path list to routes matching the route policy statement entry.

If no AS path list is specified, the AS path attribute is not changed.

The no form of this command disables the AS path list editing action from the route policy entry.

Default

no as-path

Parameters

add

Keyword to specify that the AS path list is to be prepended to an existing AS list.

replace

Keyword to specify that the AS path list replaces any existing AS path attribute.

name

Specifies the AS path list name. Allowed values are any string up to 32 characters composed of printable, 7-bit ASCII characters. If the string contains special characters (#, $, spaces, and so on), the entire string must be enclosed within double quotes.

The name specified must already be defined.

as-path-prepend

Syntax

as-path-prepend as-num [repeat]

no as-path-prepend

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

The command prepends a BGP AS number once or numerous times to the AS path attribute of routes matching the route policy statement entry.

If an AS number is not configured, the AS path is not changed.

If the optional number is specified, the AS number is prepended as many times as indicated by the number.

The no form of this command disables the AS path prepend action from the route policy entry.

Default

no as-path-prepend

Parameters

as-num

Specifies the AS number to prepend, expressed as a decimal integer.

Values

1 to 4294967295

repeat

Specifies the number of times to prepend the specified AS number, expressed as a decimal integer.

Values

1 to 50

community

Syntax

community {{add name [remove name]} | {remove name [add name]} | {replace name}}

no community

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command adds or removes a BGP community list to or from routes matching the route policy statement entry.

If no community list is specified, the community path attribute is not changed.

The community list changes the community path attribute according to the add and remove keywords.

The no form of this command disables the action to edit the community path attribute for the route policy entry.

Default

no community

Parameters

add

Keyword that adds the specified community list to an existing list of communities.

remove

Keyword that removes the specified community from the existing list of communities.

replace

Keyword to specify that the community list replaces an existing community attribute.

name

Specifies the community list name. Allowed values are any string up to 32 characters composed of printable, 7-bit ASCII characters. If the string contains special characters (#, $, spaces, and so on), the entire string must be enclosed within double quotes.

damping

Syntax

damping {name | none}

no damping

Context

config>router>policy-options>policy-statement >default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command configures a damping profile used for routes matching the route policy statement entry.

If no damping criterion is specified, the default damping profile is used.

The no form of this command removes the damping profile associated with the route policy entry.

Default

no damping

Parameters

name

Specifies the damping profile name. Allowed values are any string up to 32 characters composed of printable, 7-bit ASCII characters. If the string contains special characters (#, $, spaces, and so on), the entire string must be enclosed within double quotes.

The name specified must already be defined.

none

Keyword that disables route damping for the route policy.

default-action

Syntax

default-action {accept | next-entry | reject}

no default-action

Context

config>router>policy-options>policy-statement

Platforms

Supported on all 7210 SAS platforms as described in this document, including platforms configured in the access-uplink operating mode

Description

This command configures actions for routes that do not match any route policy statement entries when the accept parameter is specified.

The default-action command can be set to all available action states. If the action states are accepted or rejected, the policy evaluation terminates and a result is returned.

If a default action is defined and no matches occur with the entries in the policy, the default action is used.

If a default action is defined and one or more matches occur with the entries of the policy, the default action is not used.

The no form of this command deletes the default-action context for the policy statement.

Default

no default-action

Parameters

accept

Keyword to specify routes matching the entry match criteria are accepted and propagated.

next-entry

Keyword to specify that the actions specified would be made to the route attributes and then policy evaluation would continue with next policy entry (if any others are specified).

reject

Keyword to specify routes matching the entry match criteria would be rejected.

local-preference

Syntax

local-preference preference

no local-preference

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns a BGP local preference to routes matching a route policy statement entry.

If no local preference is specified, the BGP configured local preference is used.

The no form of this command disables assigning a local preference in the route policy entry.

Default

no local-preference

Parameters

preference

Specifies the local preference, expressed as a decimal integer.

Values

0 to 4294967295

metric

Syntax

metric {add | subtract | set} metric

no metric

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns a metric to routes matching the policy statement entry.

If no metric is specified, the configured metric is used. If neither is defined, no metric is advertised.

The value assigned to the metric by the route policy is controlled by the required keywords.

The no form of this command disables assigning a metric in the route policy entry.

Default

no metric

Parameters

add

Keyword to specify integer is added to any existing metric. If the result of the addition results in a number greater than 4294967295, the value 4294967295 is used.

subtract

Keyword to specify integer is subtracted from any existing metric. If the result of the subtraction results in a number less than 0, the value of 0 is used.

set

Keyword to specify integer replaces any existing metric.

metric

Specifies the metric modifier, expressed as a decimal integer.

Values

0 to 4294967295

next-hop

Syntax

next-hop ip-address

no next-hop

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns the specified next-hop IP address to routes matching the policy statement entry.

If a next-hop IP address is not specified, the next-hop attribute is not changed.

The no form of this command disables assigning a next-hop address in the route policy entry.

Default

no next-hop

Parameters

ip-address

Specifies the next-hop IP address in dotted decimal notation.

Values

ipv4-prefix:

a.b.c.d (host bits must be 0)

ipv4-prefix-length:

0 to 32

next-hop-self

Syntax

[no] next-hop-self

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command advertises a next-hop IP address belonging to this router, even if a third-party next hop is available to routes matching the policy statement entry.

The no form of this command disables advertising the next-hop-self command for the route policy entry.

Default

no next-hop-self

origin

Syntax

origin {igp | egp | incomplete}

no origin

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command sets the BGP origin assigned to routes exported into BGP.

If the routes are exported into protocols other than BGP, this option is ignored.

The no form of this command disables setting the BGP origin for the route policy entry.

Default

no origin

Parameters

igp

Keyword that sets the path information as originating within the local AS.

egp

Keyword that sets the path information as originating in another AS.

incomplete

Keyword that sets the path information as learned by some other means.

preference

Syntax

preference preference

no preference

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns a route preference to routes matching the route policy statement entry.

If no preference is specified, the default Route Table Manager (RTM) preference for the protocol is used.

The no form of this command disables setting an RTM preference in the route policy entry.

Default

no preference

Parameters

preference

Specifies the route preference, expressed as a decimal integer.

Values

1 to 255 (0 represents unset — MIB only)

tag

Syntax

tag tag

no tag

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns an OSPF tag to routes matching the entry. The tag value is used to apply a tag to a route for either an OSPF or RIP route. A hexadecimal value of 4 octets can be entered.

For OSPF, all four octets can be used.

For RIP, only the two most significant octets are used when more than two octets are configured.

The no form of this command removes the tag.

Default

no tag

Parameters

tag

Specifies to assign an OSPF or ISIS tag to routes matching the entry.

Values

Accepts decimal or hex formats:

OSPF and ISIS:

[0x0..0xFFFFFFFF]H

RIP:

[0x0..0xFFFF]H

type

Syntax

type {type}

no type

Context

config>router>policy-options>policy-statement>default-action

config>router>policy-options>policy-statement>entry>action

Platforms

Supported on all 7210 SAS platforms as described in this document

Description

This command assigns an OSPF type metric to routes matching the route policy statement entry and being exported into OSPF.

The no form of this command disables assigning an OSPF type within the route policy entry.

Default

no type

Parameters

type

Specifies the OSPF type metric.

Values

1 — Set as OSPF routes with type 1 LSAs

2 — Set as OSPF routes with type 2 LSAs