ip policy-based-route

Function

The ip policy-based-route command enables a PBR policy on an interface.

The undo ip policy-based-route command disables a PBR policy on an interface.

By default, no PBR policy is enabled on an interface.

Format

ip policy-based-route policy-name

undo ip policy-based-route [ policy-name ]

Parameters

Parameter Description Value
policy-name

Specifies the policy name.

The value is a string of 1 to 31 case-sensitive characters without spaces.

Views

GE sub-interface view, GE electrical interface view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
cli execute

Usage Guidelines

Usage Scenario

PBR is deployed in the scenario where users want specific traffic to be forwarded to a desired next hop. Each node in each traffic policy for PBR is configured with rules and an action. The action is redirecting matching IP packets to an outbound interface.

Prerequisites

A PBR policy and node have been created using the policy-based-route command.

Example

# Enable the PBR policy named AAA on GE 0/1/0.
<HUAWEI> system-view
[~HUAWEI] policy-based-route AAA permit node 1 map-instance 1
[*HUAWEI-policy-based-route-AAA-1] quit
[*HUAWEI] interface GigabitEthernet 0/1/0
[*HUAWEI-GigabitEthernet0/1/0] ip policy-based-route AAA
Copyright ? Huawei Technologies Co., Ltd.
Copyright ? Huawei Technologies Co., Ltd.
< Previous topic Next topic >