03-Layer 2—LAN Switching Command Reference

HomeSupportResource CenterReference GuidesCommand ReferencesH3C S6520X & S6520-SI & S5560X-HI & S5000-EI & MS4600 Command References-R6615Pxx-6W10103-Layer 2—LAN Switching Command Reference
16-PPP commands
Title Size Download
16-PPP commands 78.45 KB

PPPoE relay commands

PPPoE relay commands

display pppoe-relay client-information

Use display pppoe-relay client-information to display the vendor-specific tag processing configuration for client-side packets on the PPPoE relay.

Syntax

display pppoe-relay client-information { format | strategy }

Views

Any view

Predefined user roles

network-admin

network-operator

Parameters

format: Displays the format configuration for the vendor-specific tag processing for client-side packets on the PPPoE relay.

strategy: Displays the policy configuration for the vendor-specific tag processing for client-side packets on the PPPoE relay.

Examples

# Display the format configuration for the vendor-specific tag processing for client-side packets on the PPPoE relay.

<Sysname> display pppoe-relay client-information format

The current client-information format:

Circuit ID: ASCII

Remote ID: ASCII

# Display the policy configuration for the vendor-specific tag processing for client-side packets on the PPPoE relay.

<Sysname> display pppoe-relay client-information strategy

The current global client-information strategy: Replace

The current interface client-information strategy:

  Interface                     Strategy

  Ten-GigabitEthernet1/0/1            Keep

  Ten-GigabitEthernet1/0/2            Drop

Table 1 Command output

Field

Description

The current client-information format

Circuit ID and remote ID padding formats in the vendor-specific tag:

·     ASCII—ASCII string padding format.

·     Hex—Hexadecimal padding format.

·     User-defined—User-defined padding format.

The current global client-information strategy

Global vendor-specific tag processing policy for the client-side PADI and PADR packets on the PPPoE relay:

·     Drop—Strips the vendor-specific tag from the PADI or PADR packets.

·     Keep—Keeps the vendor-specific tag unchanged.

·     Replace—Pads the vendor-specific tag in the configured padding format.

The current interface client-information strategy

Interface-level vendor-specific tag processing policy for the client-side PADI and PADR packets on the PPPoE relay.

Interface

Interface name. This field displays only the interfaces whose processing policies are different from the global processing policy.

Strategy

Vendor-specific tag processing policy for the client-side PADI and PADR packets of the interface on the PPPoE relay:

·     Drop—Strips the vendor-specific tag from the PADI or PADR packets.

·     Keep—Keeps the vendor-specific tag unchanged.

·     Replace—Pads the vendor-specific tag in the configured padding format.

 

Related commands

pppoe-relay client-information format

pppoe-relay client-information strategy

display pppoe-relay statistics

Use display pppoe-relay statistics to display packets statistics for the PPPoE relay.

Syntax

display pppoe-relay 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.

Usage guidelines

When this command is executed, this command displays statistics only for packets with non-zero packet counts.

Examples

# Display packet statistics on Ten-GigabitEthernet 1/0/1.

<Sysname> display pppoe-relay statistics interface Ten-GigabitEthernet 1/0/1

Interface: Ten-GigabitEthernet1/0/1

  Packets received:

    ALL = 5 PADI = 5 PADO = 0 PADR = 0 PADS = 0 PADT = 0

  Packets sent:

    ALL = 5 PADI = 0 PADO = 5 PADR = 0 PADS = 0 PADT = 0

  Packets dropped:

    Server responses from untrusted ports = 0

    Client requests towards untrusted ports = 0

    Malformed PPPoE Discovery packets = 0

Table 2 Command output

Field

Description

Interface

Statistics on an interface.

Packets received

Incoming packet statistics of the interface:

·     ALL—Number of all PAD packets.

·     PADI—Number of PADI packets.

·     PADO—Number of PADO packets.

·     PADR—Number of PADR packets.

·     PADS—Number of PADS packets.

·     PADT—Number of PADT packets.

Packets sent

Outgoing packet statistics of the interface:

·     ALL—Number of all PAD packets.

·     PADI—Number of PADI packets.

·     PADO—Number of PADO packets.

·     PADR—Number of PADR packets.

·     PADS—Number of PADS packets.

·     PADT—Number of PADT packets.

Packets dropped

Dropped packets statistics of the interface.

Server responses from untrusted ports

Number of PADO and PADS packets dropped on untrusted ports.

Client requests towards untrusted ports

Number of PADR packets dropped by untrusted ports.

 

Related commands

reset pppoe-relay statistics

pppoe-relay client-information format

Use pppoe-relay client-information format to configure the circuit ID and remote ID padding formats for the client-side PPPoE packets on the PPPoE relay.

Use undo pppoe-relay client-information format to restore the default.

Syntax

pppoe-relay client-information format { circuit-id | remote-id } { ascii | hex | user-defined text }

undo pppoe-relay client-information format { circuit-id | remote-id }

Default

Both the circuit ID padding format and the remote ID padding format for the client-side PPPoE packets are the ASCII string on the PPPoE relay.

Views

System view

Predefined user roles

network-admin

Parameters

circuit-id: Specifies the circuit ID padding format.

remote-id: Specifies the remote ID padding format.

ascii: Specifies the ASCII string format. When this format is configured, "%portname:%svlan.%cvlan %sysname" is extracted and used as the circuit ID content, and "%mac" is used as the remote ID content. The circuit ID and remote ID are padded with the corresponding contents in the ASCII string format.

hex: Specifies the hexadecimal format. When this format is configured, "%length%port%svlan%cvlan" is extracted and used as the circuit ID content, and "%length%mac" is used as the remote ID content. The circuit ID and remote ID are padded with the corresponding contents in the hexadecimal format.

user-defined text: Specifies the user-defined format. The text argument is a case-sensitive string of 1 to 127 characters. When this format is configured, the corresponding information is extracted from the configured text and padded in the circuit ID and remote ID.

Usage guidelines

When the PPPoE relay receives PPPoE packets from the PPPoE client, the PPPoE relay pads the circuit ID and remote ID with the contents in the format configured by using this command.

Both the circuit ID and remote ID are of up to 63 characters. When the content to be padded exceeds 63 characters, the first 63 characters are padded.

When the user-defined format is used, the system automatically recognizes the escape keyword input by the user and translates it to the actual information. For more information about the supported escape keywords, see Table 3. For example, suppose the interface that receives packet on the PPPoE relay is Ethernet 0/0/0. In this case, you can input the escape keyword %portname. Then, the system automatically recognizes the escape keyword and translates the escape keyword into the actual port information Ethernet 0/0/0. For the system to correctly recognize the escape keywords, you must add the dollar sign (%) before each keyword. Otherwise, the system directly uses the input keyword and does not translate it. Non-escape keywords are directly used.

An integer can be added between the dollar sign (%) and the escape keyword. The integer specifies the width of the translated characters. When the translated characters do not reach the width specified by the integer, spaces are padded on the left to fill the width.

Table 3 Description of escape keywords supported by the user-defined format

Keyword

Description

sysname

System name of the PPPoE relay.

portname

Port name.

porttype

Port type.

slot

Slot number of the port.

subslot

Subslot number of the port.

port

Port number.

svlan

Outer VLAN ID.

cvlan

Inner VLAN ID.

mac

MAC address of the PPPoE relay.

Length

Length of the subsequent string. The padded content is of double digits. When the length is a single digit, one digit of 0 is padded on the left.

 

When you use different padding formats, the packet contents are different. For example, the contents of the circuit ID are as follows: the user access interface is Ethernet 0/0/0, the outer VLAN ID is 200, the inner VLAN ID is 100, and the system name of the PPPoE relay is Sysname. The contents of the remote ID are as follows: the MAC address of the PPPoE relay is 04f9-38a9-44b0.

When you use the ASCII string format, the contents are as follows:

  Circuit ID: Ethernet0/0/0:200.100 Sysname

  Remote ID: 04f9-38a9-44b0

When you use the hexadecimal format, the contents are as follows:

  Circuit ID: 00 05 00 00 c8 00 64

  Remote ID: 00 06 04 f9 38 a9 44 b0

When you use the user-defined format, the contents are as follows:

# Configure the user-defined format "%portname:%svlan.%cvlan %sysname" for the circuit ID.

[Sysname] pppoe-relay client-information format circuit-id user-defined "%portname:%svlan.%cvlan %sysname"

# Configure the user-defined format %mac for the remote ID.

[Sysname] pppoe-relay client-information format remote-id user-defined "%mac"

Examples

# Configure the circuit ID padding format as the ASCII string format for the client-side PPPoE packets on the PPPoE relay.

<Sysname> system-view

[Sysname] pppoe-relay client-information format circuit-id ascii

Related commands

display pppoe-relay client-information

pppoe-relay client-information strategy

pppoe-relay client-information strategy

Use pppoe-relay client-information strategy to configure the vendor-specific tag processing policy for the client-side PADI and PADR packets on the PPPoE relay.

Use undo pppoe-relay client-information strategy to restore the default.

Syntax

pppoe-relay client-information strategy { drop | keep | replace }

undo pppoe-relay client-information strategy

Default

The global vendor-specific tag processing policy for the client-side PADI and PADR packets on the PPPoE relay is replace.

No interface-level vendor-specific tag processing policy for the client-side PADI and PADR packets on the PPPoE relay is configured.

Views

System view

Layer 2 Ethernet interface view

Layer 2 aggregate interface view

Predefined user roles

network-admin

Parameters

drop: Strips the vendor-specific tag from the PADI or PADR packets.

keep: Keeps the vendor-specific tag unchanged.

replace: Pads the vendor-specific tag in the configured format.

Usage guidelines

This feature can be configured both in system view and in interface view. The configuration in system view takes effect on all interfaces. The configuration in interface view takes effect only on the current interface. The configuration in interface view takes precedence over the configuration in system view.

The processing policy takes effect only on incoming packets of interfaces.

This command is not supported on Layer 2 aggregation group member ports. If a Layer 2 Ethernet interface is configured with this command before joining a Layer 2 aggregation group, the command is cleared on the member port after the member ports joins the aggregation group.

Examples

# Configure the global processing policy for the client-side PADI and PADR packets as drop on the PPPoE relay.

<Sysname> system-view

[Sysname] pppoe-relay client-information strategy drop

Related commands

display pppoe-relay client-information

pppoe-relay client-information format

pppoe-relay enable

Use pppoe-relay enable to enable the PPPoE relay function.

Use undo pppoe-relay enable to disable the PPPoE relay function.

Syntax

pppoe-relay enable

undo pppoe-relay enable

Default

The PPPoE relay function is disabled.

Views

System view

Predefined user roles

network-admin

Examples

# Enable the PPPoE relay function.

<Sysname> system-view

[Sysname] pppoe-relay enable

pppoe-relay server-information vendor-specific strip

Use pppoe-relay server-information vendor-specific strip to enable an interface to strip the vendor-specific tags of the PPPoE server-side packets.

Use undo pppoe-relay server-information vendor-specific strip to disable an interface from stripping the vendor-specific tags of the PPPoE server-side packets.

Syntax

pppoe-relay server-information vendor-specific strip

undo pppoe-relay server-information vendor-specific strip

Default

The function of stripping vendor-specific tags of the PPPoE server-side packets is disabled on an interface.

Views

Layer 2 Ethernet interface view

Layer 2 aggregate interface view

Predefined user roles

network-admin

Usage guidelines

When the PPPoE relay receives PADO and PADS packets from the PPPoE server on a PPPoE relay trusted port with this feature enabled, the PPPoE relay strips the vendor-specific tags of the packets before forwarding the packets.

This command takes effect only on packets received on PPPoE relay trusted ports.

This command is not supported on Layer 2 aggregation group member ports. If a Layer 2 Ethernet interface is configured with this command before joining a Layer 2 aggregation group, the command is cleared on the member port after the member ports joins the aggregation group.

Examples

# Enable Ten-GigabitEthernet 1/0/1 to strip the vendor-specific tags of the PPPoE server-side packets..

<Sysname> system-view

[Sysname] interface Ten-GigabitEthernet 1/0/1

[Sysname-Ten-GigabitEthernet1/0/1] pppoe-relay trust

[Sysname-Ten-GigabitEthernet1/0/1] pppoe-relay server-information vendor-specific strip

Related commands

pppoe-relay trust

pppoe-relay trust

Use pppoe-relay trust to configure an interface as PPPoE relay trusted port.

Use undo pppoe-relay trust to restore the default.

Syntax

pppoe-relay trust

undo pppoe-relay trust

Default

An interface is a PPPoE relay untrusted port.

Views

Layer 2 Ethernet interface view

Layer 2 aggregate interface view

Predefined user roles

network-admin

Usage guidelines

A PPPoE relay-enabled device processes PPPoE protocol packets as follows:

·     When receiving PADI, PADR, and PADT on untrusted ports, the device can forward the packets out of only the trusted ports.

·     When receiving PADO and PADS packets on untrusted ports, the device directly drops the packets.

·     When receiving PADO, PADS, and PADT packets on trusted ports, the device can forward the packets out of any port.

·     When receiving PADI and PADR packets on trusted ports, the device can forward the packets out of only the trusted ports.

For a PPPoE relay to correctly forward and process PPPoE protocol packets, you must configure the PPPoE server-facing interfaces on the PPPoE relay as trusted ports, and configure the PPPoE client-facing interfaces on the PPPoE relay as untrusted ports.

This command is not supported on Layer 2 aggregation group member ports. If a Layer 2 Ethernet interface is configured with this command before joining a Layer 2 aggregation group, the command is cleared on the member port after the member ports joins the aggregation group.

Examples

# Configure Ten-GigabitEthernet 1/0/1 as a PPPoE relay trusted port.

<Sysname> system-view

[Sysname] interface Ten-GigabitEthernet 1/0/1

[Sysname-Ten-GigabitEthernet1/0/1] pppoe-relay trust

Related commands

pppoe-relay server-information vendor-specific strip

reset pppoe-relay statistics

Use reset pppoe-relay statistics to clear packets statistics for the PPPoE relay.

Syntax

reset pppoe-relay statistics

Views

User view

Predefined user roles

network-admin

Examples

# Clear packet statistics for the PPPoE relay.

<Sysname> reset pppoe-relay statistics

Related commands

reset pppoe-relay statistics

 

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