This task configures a logical interface on a physical (Ethernet) port and a port-channel (Link Aggregation Group, or LAG) interface.
About this task
Refer to the Usage Guidelines for the
logical-interface command for complete details.
Procedure
-
Do the following to configure a logical interface on an Ethernet port.
-
Enter global configuration mode.
device# configure terminal
-
Specify an Ethernet interface.
device(config)# interface ethernet 0/6
-
Enter the
switchport command to configure the parent interface as switchport.
device(conf-if-eth-0/6)# switchport
-
Enter the
switchport mode trunk-no-default-native command to enable an explicit untagged LIF to be configured.
device(conf-if-eth-0/6)# switchport mode trunk-no-default-native
-
Enable the interface.
device(conf-if-eth-0/6)# no shutdown
-
Enter the
logical-interface command, specify a service instance, and enter LIF configuration mode.
device(conf-if-eth-0/6)# logical-interface ethernet 0/6.120
-
(Optional) Enter the
name command to facilitate the management of the LIF.
device(conf-if-eth-lif-0/6.120)# name myLIF120
-
Enter the
vlan command with the
inner-vlan option to specify an interface and create dual-tag VLANs.
device(conf-if-eth-lif-0/6.120)# vlan 120 inner-vlan 200
-
Alternatively, enter the
untagged vlan command to specify that the LIF is to receive untagged packets.
device(conf-if-eth-lif-0/6.120)# untagged vlan 120
See the Usage Guidelines for the
vlan (LIF)
command.
-
(Optional) By default, the administrative state of the LIF is "no shutdown." To remove the port from participating in any data traffic without having to shut down the physical interface, enter the
no form of the
shutdown (LIF)
command.
device(conf-if-eth-lif-0/6.120)# no shutdown
-
(Optional) For convenience, you can also enter up to two options in a single command line, as in the following examples.
device(conf-if-eth-0/6)# logical-interface ethernet 0/6.120 name myLIF120
device(conf-if-eth-0/6)# logical-interface ethernet 0/6.120 vlan 120
-
To configure a port-channel, configure the basic LIF parameters and options as in Step 1.
-
Specify a port-channel, set its mode to "trunk-no-default-native," and specify a logical interface service instance.
device(config)# interface port-channel 10
device(config-port-channel-10)# switchport mode trunk-no-default-native
device(config-port-channel-10)# logical-interface port-channel 10.3
device(config-if-po-lif-10.3)#
-
Repeat additional substeps in Step 1 as appropriate.