EdgeRouter – Add VLANs to switch interface


Readers will learn how to add VLANs to a switch interface.

Note: This configuration only works on models with built-in switch port (e.g., EdgeRouter-PoE-5-Port).


The following commands create a VIF (Virtual Interface) VLAN ID of 1001 on interface switch0 (switch):

configure set interfaces switch switch0 vif 1001 address  commit exit 

In this particular example I configured this interface with IP address, you can replace this IP address with the one you want to use on this interface.


To display the configurations of your Ethernet interfaces, use the show interfaces ethernet command:

ubnt@ubnt:~$ show interfaces ethernet  Codes: S - State, L - Link, u - Up, D - Down, A - Admin Down Interface    IP Address                        S/L  Description                  ---------    ----------                        ---  -----------                  eth0                     u/u                               eth1                     u/u                               eth2                     u/u
switch0 - u/u
switch0.1001 u/u ubnt@ubnt:~$

Leave a Reply

Your email address will not be published. Required fields are marked *