R3721-F3210-F3171-HP High-End Firewalls Network Management Command Reference-6PW101

20
Default level
2: System level
Parameters
bridge: Specifies the Layer 2 mode.
route: Specifies the Layer 3 mode.
interface-list: Specifies an Ethernet interface list, in the format of interface-type interface-number [ to
interface-type interface-number ] &<1-10>, where &<1-10> indicates that you can specify up to 10
interfaces or interface ranges.
Description
Use port link-mode interface-list to change the link mode of Ethernet interfaces.
Depending on the hardware structure of interface cards, for a device, some interfaces can operate only
as Layer 2 Ethernet interfaces (in bridge mode), some can operate only as Layer 3 Ethernet interfaces (in
route mode), and others can operate either as Layer 2 or Layer 3 Ethernet interfaces (you can use
commands to set the link mode to bridge or route).
Configuring the port link-mode interface-list command in system view and configuring the port
link-mode command in Ethernet interface view lead to the same result. The difference between the two
commands is that the former changes the link mode of multiple Ethernet interfaces in batch, and the latter
changes the link mode of one Ethernet interface at a time.
CAUTION:
After you change the link mode of an Ethernet interface, all the settings of the Ethernet interface are
restored to their defaults under the new link mode.
The link mode configuration for an Ethernet interface in system view and that in interface view supersede
each other, and the one configured last takes effect.
Examples
# Configure GigabitEthernet 0/1 through GigabitEthernet 0/5 to operate in Layer 2 mode.
<Sysname> system-view
[Sysname] port link-mode bridge gigabitethernet 0/1 to gigabitethernet 0/5
# Configure GigabitEthernet 0/1 through GigabitEthernet 0/5 to operate in Layer 3 mode.
<Sysname> system-view
[Sysname] port link-mode route gigabitethernet 0/1 to gigabitethernet 0/5
reset counters interface
Syntax
reset counters interface [ interface-type [ interface-number | interface-number.subnumber ] ]
View
User view
Default level
2: System level
Parameters
interface-type: Specifies an interface type.