< Home

apply tag

Function

The apply tag command sets the action for changing the tag of routes in a routing policy.

The undo apply tag command restores the default setting.

By default, the action for changing the tag of routes is not set in a routing policy.

Format

apply tag tag

undo apply tag

Parameters

Parameter Description Value
tag Specifies the tag of routes. Routes can be tagged as required. You can set the same tag for the same type of route. Routes can be flexibly controlled and managed through tags in the routing policy. The value is an integer ranging from 0 to 4294967295.

Views

Route-Policy view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

To identify the routes, you can apply a routing policy containing the apply tag command to add the same tag to the matched routes.

Prerequisites

The apply tag command can be used only after the route-policy command is used.

Precautions

When a routing policy takes effects, routes will be matched by routing policies related to the tag.

BGP routes do not support tags. The apply tag command sets the tag for only IGP routes.

Example

# Set the tag of routes to 100.

<HUAWEI> system-view
[HUAWEI] route-policy policy permit node 10
[HUAWEI-route-policy] apply tag 100
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >