OPNsense Forum

English Forums => General Discussion => Topic started by: cosmos on August 29, 2025, 09:20:46 PM

Title: Same VLAN on opnsense router port
Post by: cosmos on August 29, 2025, 09:20:46 PM
Hi all.

I want the following but have no clue how to do this the right way.

On my opnsense box with multiple ethernet ports, I have one port that goes to my managed main switch serving all my VLAN's and this works great.

But, to offload some traffic coming via that route of my main managed switch, I would like to have one of those VLAN's to be also present on of the free ports on the opnsense box directly.

How can I achieve this the right way? Just create an VLAN interface with the same id on one of the free ports? Or will this not work?

The VLAN needs to be also available through my managed switches.

Can somebody please point me into the right direction?
Title: Re: Same VLAN on opnsense router port
Post by: viragomann on August 29, 2025, 09:36:24 PM
Quote from: cosmos on August 29, 2025, 09:20:46 PMHow can I achieve this the right way? Just create an VLAN interface with the same id on one of the free ports? Or will this not work?
No, a VLAN is just necessary to run multiple network segment on the same hardware (network port, cable). But you have different network adapters (vitual + hardware), which you want to have the same network segment on.
In this case you need to brdge (https://docs.opnsense.org/manual/other-interfaces.html#bridge) these network adapters.
Title: Re: Same VLAN on opnsense router port
Post by: Patrick M. Hausen on August 29, 2025, 10:07:11 PM
You need to create a bridge interface with two members:

- the VLAN interface on the trunk port connected to your switch
- the plain ethernet port you want to be part of that VLAN

Then you need to switch the assignment (Interfaces > Assignments) from the VLAN to the bridge interface.

You are essentially building a virtual switch with an untagged port and a VLAN as member interfaces.
Title: Re: Same VLAN on opnsense router port
Post by: cosmos on August 29, 2025, 10:23:55 PM
Thank you!