set interface gigabit-ethernet family ethernet-switching port-mode
The set interface gigabit-ethernet family ethernet-switching port-mode command configures the port mode of a switch port.
Command Syntax
set interface gigabit-ethernet <interface-name> family ethernet-switching port-mode <port-mode>
Parameter
Parameter | Description |
gigabit-ethernet <interface-name> | Specifies a physical port name. The value is like ge-1/1/1, te-1/1/3. |
port-mode <port-mode> | Specifies the port mode. The value could be access, trunk, pvlan-host, pvlan-secondary-trunk, pvlan-promiscuous or pvlan-promiscuous-trunk.
By default, the port mode is access. |
Usage Guidelines
There are six port modes, the last four of these modes are used in the PVLAN configuration. Only configured with the PVLAN port mode, a port can be added into a private VLAN.
Characteristics of different interfaces are:
- Access Port
An access interface connects to a user device. It can connect only to an access link, and Ethernet frames transmitted on the access link are untagged. An access interface adds a VLAN tag to packets and sets the VID field in the VLAN tag to the native VLAN ID.
- Trunk Port
A trunk interface connects to a switch and can connect only to a trunk link. A trunk interface allows frames from multiple VLANs to pass.
- PVLAN Host Port
A PVLAN host port connects to a user device. For host mode ports, make sure that their native VLAN is a secondary VLAN, otherwise the ports cannot forward packets from primary VLAN. One host port can be added into only one secondary VLAN.
Packets sent from this port will be untagged.
- PVLAN Secondary Trunk Port
A PVLAN secondary trunk port is used to connect to the downstream devices. One secondary trunk port can be added into only one secondary VLAN.
Packets sent from this port will be tagged with the secondary VLAN ID.
- PVLAN Promiscuous Port
A PVLAN promiscuous port is used to connect to the uplink devices and are used for communicating with the uplink device. Uplinks are typically ports that connect to routers, firewalls, servers or provider networks.
Promiscuous ports belong to the primary VLAN and can communicate with all PVLAN ports, including the host ports and other promiscuous ports within the same primary VLAN.
A promiscuous port can serve only one primary VLAN, one isolated VLAN, and multiple community VLANs.
Make sure that the native VLAN of the promiscuous port is the primary VLAN, otherwise the ports cannot forward packets from secondary VLANs.
Promiscuous port applies when there is only one primary VLAN passing through the uplink port, and packets sent from this port will not be tagged.
- PVLAN Promiscuous Trunk Port
A PVLAN promiscuous trunk port is used to connect to the uplink devices and are used for communicating with the uplink device.
Promiscuous trunk port applies when there is only one primary VLAN passing through the uplink port, the difference with the promiscuous port is that, the packets sent from the promiscuous trunk port will be tagged with the primary VLAN ID. Other than that, the port behaves just like a promiscuous port.
For promiscuous trunk ports, make sure that their native VLAN is the primary VLAN, otherwise the ports cannot forward packets from secondary VLAN.
NOTE:
|
Example
- Configure the port mode of ge-1/1/1 to access.
admin@Xorplus# set interface gigabit-ethernet ge-1/1/1 family ethernet-switching port-mode access admin@Xorplus# commit
Copyright © 2025 Pica8 Inc. All Rights Reserved.