The portswitch command changes the working mode of a virtual Ethernet (VE) interface from Layer 3 mode to Layer 2 mode.
The undo portswitch command changes the working mode of a VE interface from Layer 2 mode to Layer 3 mode.
By default, a VE interface works in Layer 3 mode.
Only the S5720-HI, S5730-HI, S5731-H, S5731-S, S5731S-H, S5731S-S, S5732-H, S6720-HI, S6730-H, S6730S-H, S6730-S, and S6730S-S support this command.
Usage Scenario
By default, a VE interface on the device works in Layer 3 mode. To enable Layer 2 forwarding on the VE interface, run the portswitch command to change the working mode to Layer 2 mode.
Precautions
If an interface has the non-attribute configuration, this command cannot be executed. Before running this command, delete the non-attribute configuration on the interface.
The minimum interval between running the portswitch and undo portswitch commands must be 30s.