04-Layer 2 - LAN Switching

HomeSupportReference GuidesCommand ReferencesH3C Access Controllers Command References(E5208P03 E5215P01 R5215P01)-6W10204-Layer 2 - LAN Switching
07-Layer 2 forwarding commands
Title Size Download
07-Layer 2 forwarding commands 67.29 KB

Layer 2 forwarding commands

The WX1800H series, WX2500H series, and WX3000H series access controllers do not support the slot keyword or the slot-number argument.

Normal Layer 2 forwarding commands

display mac-forwarding statistics

Use display mac-forwarding statistics to display Layer 2 forwarding statistics.

Syntax

display mac-forwarding statistics [ interface interface-type interface-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

interface interface-type interface-number: Specifies an interface by its type and number. If you do not specify this option, the command displays Layer 2 forwarding statistics on all interfaces.

Examples

# Display Layer 2 forwarding statistics on all interfaces.

<Sysname> display mac-forwarding statistics

Input:

   Sum:               888        Unknown Unicast:   0

   Broadcast:         0          Multicast:         0

   Filtered:          0          STP discarded:     0

   Service dropped:   0          Source dropped:    0

   Unknown dropped:   0          Learning dropped:  0

   Attack dropped:    0          Suppress dropped:  0

Deliver:

   Sum:               111        L2 protocol:       11

   Local MAC address: 100

Output:

   Sum:               666        Filtered:          0

   Blackhole dropped: 0          STP discarded:     0

   Service dropped:   0          Dest MAC dropped:  0

# Display Layer 2 forwarding statistics on GigabitEthernet 1/0/1.

<Sysname> display mac-forwarding statistics interface gigabitethernet 1/0/1

GigabitEthernet 1/0/1:

Input frames: 100    Output frames:100

Filtered:     0

Table 1 Command output

Field

Description

Input

Inbound Ethernet frame statistics.

Sum

Total number of received Ethernet frames.

Filtered

Number of Ethernet frames filtered out by 802.1Q VLAN inbound filtering rules.

STP discarded

Number of inbound Ethernet frames dropped on the ports blocked by STP.

Service dropped

Number of Ethernet frames dropped by inbound service features.

Source dropped

Number of Ethernet frames dropped because their source MAC addresses are all-zeros, multicast, or broadcast MAC addresses.

Unknown dropped

Number of Ethernet frames dropped because the device is disabled from forwarding frames with unknown source MAC addresses.

Learning dropped

Number of Ethernet frames dropped because the device is disabled from forwarding unknown frames after the number of learned MAC addresses reaches the upper limit.

Attack dropped

Number of attack Ethernet frames dropped by features based on the source MAC addresses.

Suppress dropped

Number of Ethernet frames dropped by storm suppression.

Broadcast

Number of received broadcast Ethernet frames.

Multicast

Number of received multicast Ethernet frames.

Unknown Unicast

Number of received unknown unicast Ethernet frames.

Deliver

Statistics of Ethernet frames delivered to the CPU.

Sum

Total number of Ethernet frames delivered to the CPU.

L2 protocol

Number of Layer 2 protocol Ethernet frames delivered to the CPU.

Local MAC address

Number of Ethernet frames with the destination MAC addresses being the MAC addresses of local Layer 3 VLAN interfaces.

Output

Outbound Ethernet frame statistics.

Sum

Total number of sent Ethernet frames.

Blackhole dropped

Number of Ethernet frames dropped because they are destined for blackhole MAC addresses.

Filtered

Number of Ethernet frames filtered out by 802.1Q VLAN outbound filtering rules.

STP discarded

Number of outbound Ethernet frames dropped on the ports blocked by STP.

Service dropped

Number of Ethernet frames dropped by outbound service features.

Dest MAC dropped

Number of Ethernet frames dropped by features based on the destination MAC addresses.

Input frames

Number of Ethernet frames received on the interface.

Output frames

Number of Ethernet frames sent out of the interface.

Filtered

Number of Ethernet frames filtered out because they are from other VLANs.

 

reset mac-forwarding statistics

Use reset mac-forwarding statistics to clear Layer 2 forwarding statistics.

Syntax

reset mac-forwarding statistics

Views

User view

Predefined user roles

network-admin

network-operator

Examples

# Clear Layer 2 forwarding statistics.

<Sysname> reset mac-forwarding statistics

Fast Layer 2 forwarding commands

display mac-forwarding cache ip

Use display mac-forwarding cache ip to display IPv4 fast forwarding entries.

Syntax

display mac-forwarding cache ip [ ip-address ] [ slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

ip-address: Specifies an IPv4 address. If you do not specify an IPv4 address, this command displays all IPv4 fast forwarding entries.

slot slot-number: Specifies an IRF member device by its member ID. If you do not specify a member device, this command displays IPv4 fast forwarding entries for all member devices.

Examples

# Display all IPv4 fast forwarding entries.

<Sysname> display mac-forwarding cache ip

Total number of mac-forwarding entries: 2

SIP            SPort DIP             DPort Pro Input_If    Output_If   VLAN

1.1.1.2        99    1.1.1.1         2048  1   GE1/0/1     GE1/0/1     2

1.1.1.1        98    1.1.1.2         2012  1   GE1/0/2     GE1/0/2     2

Table 2 Command output

Field

Description

Total number of mac-forwarding entries

Total number of IPv4 fast forwarding entries.

SIP

Source IPv4 address.

SPort

Source port number.

DIP

Destination IPv4 address.

DPort

Destination port number.

Pro

Protocol number.

Input_If

Input interface type and number.

If no input interface is involved in fast forwarding, this field displays N/A.

If no input interface is available, this field displays a hyphen (-).

Output_If

Output interface type and number.

If no output interface is involved in fast forwarding, this field displays N/A.

If no output interface is available, this field displays a hyphen (-).

VLAN

VLAN ID.

 

display mac-forwarding cache ip fragment

Use display mac-forwarding cache ip fragment to display IPv4 fast forwarding entries for fragments.

Syntax

display mac-forwarding cache ip fragment [ ip-address ] [ slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

ip-address: Specifies an IPv4 address. If you do not specify an IPv4 address, this command displays IPv4 fast forwarding entries for all fragments.

slot slot-number: Specifies an IRF member device by its member ID. If you do not specify a member device, this command displays IPv4 fast forwarding entries for fragments on all member devices.

Examples

# Display IPv4 fast forwarding entries for all fragments.

<Sysname> display mac-forwarding cache ip fragment

Total number of fragment mac-forwarding entries: 2

SIP             SPort DIP             DPort Pro Input_If    ID     VLAN

1.1.1.1         117   1.1.1.2         0     1   GE1/0/1     2828   1

1.1.1.2         110   1.1.1.1         67    17  GE1/0/2     2322   1

Table 3 Command output

Field

Description

Total number of fragment mac-forwarding entries

Total number of IPv4 fast forwarding entries for fragments.

SIP

Source IPv4 address.

SPort

Source port number.

DIP

Destination IPv4 address.

DPort

Destination port number.

Pro

Protocol number.

Input_If

Input interface type and number.

If no input interface is involved in fast forwarding, this field displays N/A.

If no input interface is available, this field displays a hyphen (-).

ID

Fragment ID.

VLAN

VLAN ID.

 

display mac-forwarding cache ipv6

Use display mac-forwarding cache ipv6 to display IPv6 fast forwarding entries.

Syntax

display mac-forwarding cache ipv6 [ ipv6-address ] [ slot slot-number ]

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

ipv6-address: Specifies an IPv6 address. If you do not specify an IPv6 address, this command displays all IPv6 fast forwarding entries.

slot slot-number: Specifies an IRF member device by its member ID. If you do not specify a member device, this command displays IPv6 fast forwarding entries for all member devices.

Examples

# Display all IPv6 fast forwarding entries.

<Sysname> display mac-forwarding cache ipv6

Total number of IPv6 mac-forwarding items: 1

Src IP: 2002::1                                        Src port: 129

Dst IP: 2001::1                                        Dst port: 65535

VLAN ID: 2

Protocol: 2

Input interface: GE1/0/2

Output interface: GE1/0/1

Table 4 Command output

Field

Description

Total number of IPv6 mac-forwarding items

Total number of IPv6 fast forwarding entries.

Src IP

Source IPv6 address.

Src port

Source port number.

Dst IP

Destination IPv6 address.

Dst port

Destination port number.

Protocol

Protocol number.

Input interface

Input interface type and number.

If no input interface is involved in fast forwarding, this field displays N/A.

If no input interface is available, this field displays a hyphen (-).

Output interface

Output interface type and number.

If no output interface is involved in fast forwarding, this field displays N/A.

If no output interface is available, this field displays a hyphen (-).

 

  • Cloud & AI
  • InterConnect
  • Intelligent Computing
  • Intelligent Storage
  • Security
  • SMB Products
  • Intelligent Terminal Products
  • Product Support Services
  • Technical Service Solutions
All Services
  • Resource Center
  • Policy
  • Online Help
  • Technical Blogs
All Support
  • Become A Partner
  • Partner Policy & Program
  • Global Learning
  • Partner Sales Resources
  • Partner Business Management
  • Service Business
All Partners
  • Profile
  • News & Events
  • Online Exhibition Center
  • Contact Us
All About Us
新华三官网