Layer 2 Configuration

You can configure any interface of Cisco Nexus 3550-T Programmable Switch Platform to be a part of the Layer 2 network by configuring it to be a switch port through the CLI.

To configure a port in Layer 2 mode, using the following command:

admin@NX-3550-T(config)# int eth4 switchport

Create VLANs

The Nexus 3550-T enables you to create VLANs by using the CLI.

To create a VLAN, use the following command:

admin@NX-3550-T(config)# vlan 100

To dump all the VLANs configured in Nexus 3550-T, use the following command:

admin@NX-3550-T(config)# sho vlan
VLAN Ports                 
---- ----------------------
1    ethernet4;            
10    ethernet2; ethernet3; ethernet4;
100

While acting as a port of the Layer 2 network, the switch port must work in either the Access mode or Trunk mode.

Configure Access and Trunk Modes on Interfaces

When you configure an interface to operate in Access mode, it can receive and transmit only untagged frames. However, if you configure an interface in Trunk mode, then it can receive and transmit both untagged frames and tagged frames. The untagged frames in Trunk mode belong to the native VLAN configured for that port.

Configure Access Mode

It is possible to configure any interface of Nexus 3550-T to work in Access mode through the CLI, by using the following command:

admin@NX-3550-T(config)# int et2 switchport mode access

By default, any port that you configure to work in Access mode becomes a member of VLAN 1, which is the default VLAN. You can change the Access VLAN membership through the CLI by using the following command:

admin@NX-3550-T(config)# int et2 switchport access vlan 10

Configure Trunk Mode

It is possible to configure any interface of Nexus 3550-T to work in Trunk mode by using the CLI, by using the following command:

admin@NX-3550-T(config)# int et4 switchport mode trunk

By default, any port that you configure to work in Trunk mode becomes a member of VLAN 1, which is the default VLAN, as well as all other VLANs configured in the switch. For example, say the switch already had a VLAN 10, prior to configuring et2 to work in Trunk mode. So, post-configuration, et4 will become part of both VLAN 1 and VLAN 10.

When you configure a port to operate in Trunk mode, it allows users to configure native VLAN and allowed VLANs. All the packets travelling through native VLAN will be untagged packets. You can configure the native VLAN via CLI by using the following command:

admin@NX-3550-T(config)# int et4 switchport trunk native vlan 100

The Nexus 3550-T CLI also has commands to configure the list of allowed VLANs for a trunk port. You can configure either of the following options for allowed VLANs:

  • none: This option blocks all the VLAN traffic flowing through the trunk port.
  • all: This option allows traffic matching to any of the configured VLANs to flow through the trunk port.
  • add: With this option, you can add either a range of VLANs or a specific VLAN to flow through the trunk port.
  • remove: With this option, you can remove either a range of VLANs or a specific VLAN to flow through the trunk port.
  • except With this option, you can block either a range of VLANs or a specific VLAN to flow through the trunk port. All other VLANs except those specified in the command are allowed to flow through the trunk port.

The CLI commands with these options are as follows:

admin@NX-3550-T(config)# int et4 switchport trunk allowed vlan none
admin@NX-3550-T(config)# int et4 switchport trunk allowed vlan all
admin@NX-3550-T(config)# int et4 switchport trunk allowed vlan add 1-500
admin@NX-3550-T(config)# int et4 switchport trunk allowed vlan rem 1-50
admin@NX-3550-T(config)# int et4 switchport trunk allowed vlan exc 10-30

The CLI command to configure a specific vlan or a range of allowed vlans by overriding the current configured vlans is:

admin@NX-3550-T(config)# int et4 switchport trunk allowed vlan 100-500

To verify the current configuration for a port, use the sh ru int et4 command.

To dump all the information about the VLAN port membership, use the following command:

admin@NX-3550-T(config)# show vlan
VLAN Ports                 
---- ----------------------
1    ethernet4;            
10    ethernet2; ethernet4;

Spanning Tree Protocol (STP)

Nexus 3550-T uses Linux kernel's implementation of Spanning Tree Protocol, which implements the IEEE 802.1D specification. All VLANs share a single instance of STP.

warn.gif

Warningblank.gifNexus 3550-T STP is interoperable with STP, RSTP and MSTP only. It is not interoperable with PVST+ or other proprietary variants.


With the Nexus 3550-T CLI, you can configure the bridge priority, port cost and port priority.

Assign Bridge Priority

To configure the bridge priority, use the following CLI command:

admin@NX-3550-T# config spanning-tree priority 65535

To verify the configured bridge priority, use the following CLI command:

admin@NX-3550-T# show running-config spanning-tree
spanning-tree priority 65535

Assign Port Cost

By using CLI commands, you can configure the port cost for a specific interface. You can set the cost to a specific value within the range of 0 to 65535 or set the cost in auto mode where the cost is assigned automatically.

To assign a specific port cost, use the following CLI command:

admin@NX-3550-T# config int et2 spanning-tree cost 65535

To assign the port cost automatically, use the following CLI command:

admin@NX-3550-T# config int et2 spanning-tree cost auto

Assign Port Priority

You can configure the port priority in the range of 0 to 252 in a multiples of 4 for a specific interface.

To configure the port priority use the following CLI command:

admin@NX-3550-T# config int et1 spanning-tree port-priority 240

To verify the configured port priority using the following CLI command:

admin@NX-3550-T# show running-config int et2
interface ethernet2
speed 10000
switchport mode access
switchport access vlan 10
spanning-tree cost 65535
spanning-tree priority 240
ip pim rp 192.168.10.2 224.0.0.0/4
hostname NX-3550-T
ip name-server 100.100.100.148
vrf context management
ip route 0.0.0.0/0 10.10.10.1

LLDP

Through the Nexus 3550-T CLI, you can dump the LLDP neighbors learned on each port. You have the following options:

  • Dump all neighbors
  • Dump only interface specific neighbors
  • Dump only the details of LLDP entries

To dump all the entries, use the following CLI command:

admin@NX-3550-T# show lldp neighbors
Local Interface Chassis ID Port ID System Name
--------------- ---------- ------- -----------

If you require interface-specific information, use the following CLI command to dump information specific to that interface:

admin@NX-3550-T# show lldp neighbors interface et1
Local Interface Chassis ID Port ID System Name
--------------- ---------- ------- -----------

To dump information for all the interfaces, use the following CLI command:

admin@NX-3550-T# show lldp neighbors detail
Interface ethernet1 detected 0 LLDP neighbors:
Interface ethernet2 detected 0 LLDP neighbors:
--------------- ---------- ------- -----------
Interface ethernet48 detected 0 LLDP neighbors:

Configure MAC Address Tables

The MAC address tables store the MAC addresses learned at various Layer 2 ports.

To dump the contents of the MAC address tables, use the following CLI command:

admin@NX-3550-T# show mac-address-table
VLAN MAC Address  Age Interface
---- ------------ --- ---------
10   643F5F01A251 10  ethernet2
10   643F5F01A252 16  ethernet3

To add the static MAC address for a specific port, use the following CLI command:

admin@NX-3550-T# conf mac-address-table static 64:3F:5F:01:A2:54 vlan 10 interface et3

The above command adds a static MAC address that you can verify using the below CLI command. The static entries will have the age as 0.

admin@NX-3550-T# show mac-address-table
VLAN MAC Address  Age Interface
---- ------------ --- ---------
10   643F5F01A251 134 ethernet2
10   643F5F01A252 127 ethernet3
10   643F5F01A253 0   ethernet3