Access Control List Commands 4

mac access-group

This command binds a port to a MAC ACL. Use the no form to remove the port.

Syntax

mac access-group acl_name {in out}

acl_name – Name of the ACL. (Maximum length: 16 characters)

in – Indicates that this list applies to ingress packets.

out – Indicates that this list applies to egress packets.

Default Setting

None

Command Mode

Interface Configuration (Ethernet Ports 1-8)

Command Usage

A port can only be bound to one ACL.

If a port is already bound to an ACL and you bind it to a different ACL, the switch will replace the old binding with the new one.

You must configure a mask for an ACL rule before you can bind it to a port.

Example

Console(config)#interface ethernet 1/2

Console(config-if)#mac access-group jerry in

Console(config-if)#

Related Commands

show mac access-list(4-103)

show mac access-group

This command shows the ports assigned to MAC ACLs.

Command Mode

Privileged Exec

Example

Console#show mac access-group

Interface ethernet 1/5

MAC access-list M5 out

Console#

Related Commands

mac access-group(4-107)

4-107