apply policy

Syntax

apply policy <POLICY-NAME> in

no apply policy <POLICY-NAME> in

Description

Applies a policy to the current interface context.

Only one direction (inbound) of policy can be applied to a port at a time, thus using the apply command on an interface with an already-applied policy of the same direction and type will replace the currently applied policy.

The no form of this command removes a policy from the specified interface.

Command context

config-if

Parameters

<POLICY-NAME>

Specifies the policy to apply.

in

Specifies apply the policy to inbound (ingress) traffic.

Authority

Administrators

Examples

Applying a policy to a port:

switch(config)# interface 1/1/1
switch(config-if)# apply policy MY_POLICY in

Removing a policy from a port:

switch(config)# interface 1/1/1
switch(config-if)# no apply policy MY_POLICY in