route-target (EVPN)

Enables auto-generation of the import and export route-target community attributes for an Ethernet Virtual Private Network (EVPN) default instance.

Syntax

route-target { both | import } auto [ ignore-as ]
route-target export auto
no route-target { both | import } auto [ ignore-as ]
no route-target export auto

Command Default

Disabled.

Parameters

both auto
Specifies auto-generation of the import and export route-target community attributes.
ignore-as
Specifies that the autonomous system (AS) number be ignored.
export auto
Specifies auto-generation of the export route-target community attribute.
import auto
Specifies auto-generation of the import route-target community attribute.

Modes

EVPN configuration mode

Usage Guidelines

The no form of this command removes configured route target parameters.

Examples

The following example configures auto-generation of the import and export route-target community attributes for EVPN default instance.

device# configure terminal
device(config)# evpn
device(config-evpn-default)# route-target both auto

The following example configures auto-generation of the import route-target community attribute and specifies that the AS path be ignored to the route for EVPN default instance.

device# configure terminal
device(config)# evpn
device(config-evpn-default)# route-target import auto ignore-as

The following example configures auto-generation of the export route-target community attribute for EVPN myinstance instance.

device# configure terminal
device(config)# evpn myinstance
device(config-evpn-myinstance)# route-target export auto