Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Configure LAN port as VLAN?

    Scheduled Pinned Locked Moved L2/Switching/VLANs
    7 Posts 2 Posters 583 Views 3 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C Offline
      Cabledude
      last edited by Cabledude

      Hi folks,
      Can I configure an unused physical LAN port to connect a client device to a VLAN?

      Let me explain:

      • My basic setup is Netgate firewall -> LAN port -> UniFi switch -> client devices in separate VLANs.
      • The LAN port on the Netgate firewall outputs a trunk with several tagged VLANs, which are then separated in the Unifi switch to untagged ports
      • E.g. in pfSense I have IoT VLAN100 defined and tied to the LAN port. In the UniFi switch I designate VLAN100 to a specific port and connect a client device that should be on VLAN100.

      Now if the UniFi switch ports are all occupied or if the UniFi switch is placed too far away, I would like to connect a client device directly to an unused port on the Netgate firewall and I want it to be on VLAN100. For this I would like to use the OPT port on an SG-1100 or the WAN2 port on an SG-4100.

      How would I configure this? The VLAN100 is already tied to the LAN (SG-1100)/LAN1(SG-4100) port (tagged) but I also want that VLAN tied to the OPT(SG-1100)/LAN2(SG-4100) on the Netgate (untagged).

      Could this be what Bridge is for? Would I enable the interface OPT(SG-1100)/WAN2(SG-4100) with IPv4/IPv6 configuration type set to "None" and then bridge it together with VLAN100?

      Thanks,
      Pete

      Pete
      Home: SG-2100 + UniFi + Synology. SG-1100 retired
      Parents: SG-1100 + UniFi + Synology
      Testing: SG-1100 w/ 120GB SSD via ext USB (eMMC dead). Works great

      1 Reply Last reply Reply Quote 0
      • C Offline
        Cabledude
        last edited by Cabledude

        Maybe a picture explains it better:
        c38b5631-b9d1-40ce-bdc2-4447785a3a2d-image.jpeg

        Pete
        Home: SG-2100 + UniFi + Synology. SG-1100 retired
        Parents: SG-1100 + UniFi + Synology
        Testing: SG-1100 w/ 120GB SSD via ext USB (eMMC dead). Works great

        1 Reply Last reply Reply Quote 0
        • AndyRHA Offline
          AndyRH
          last edited by

          Unless the one plugged into the FW needs the use of broadcast I would argue to just add a new LAN with some rules. It might be a misconception that they all have to be in the same network. Either way the traffic will pass through the FW.

          o||||o
          7100-1u

          C 1 Reply Last reply Reply Quote 0
          • C Offline
            Cabledude @AndyRH
            last edited by

            @AndyRH said in Configure LAN port as VLAN?:

            Unless the one plugged into the FW needs the use of broadcast I would argue to just add a new LAN with some rules. It might be a misconception that they all have to be in the same network. Either way the traffic will pass through the FW.

            Thank you @AndyRH for your reply and the time you took to look at my question. Highly appreciated.
            I could add a new LAN, yes, but having to duplicate the set of firewall rules is not preferred from a “clean management” point of view. In case of any changes I would need to remember to update both sets.
            Now that you suggest a workaround, am I right to assume that there isn’t any simple solution to get the LAN4 interface on the VLAN100 network?

            Thanks,
            Pete

            Pete
            Home: SG-2100 + UniFi + Synology. SG-1100 retired
            Parents: SG-1100 + UniFi + Synology
            Testing: SG-1100 w/ 120GB SSD via ext USB (eMMC dead). Works great

            1 Reply Last reply Reply Quote 0
            • AndyRHA Offline
              AndyRH
              last edited by

              Bridging ports is a valid, but frequently a less efficient solution that brings it own challenges.
              There are many threads on bridging ports and how to do it.

              o||||o
              7100-1u

              C 1 Reply Last reply Reply Quote 0
              • C Offline
                Cabledude @AndyRH
                last edited by

                @AndyRH said in Configure LAN port as VLAN?:

                Bridging ports is a valid, but frequently a less efficient solution that brings it own challenges.
                There are many threads on bridging ports and how to do it.

                Alright, thank you so much. I will do a search.

                I've decided to follow your advice 😀 because I did hear you loud and clear about bridging being less efficient and also from your previous post that you recommend to create a separate LAN with some rules. So that is how I solved the issue.

                BUT:
                I also want to learn new things and I want to get it working (port on same VLAN100) just to learn and experiment.

                SO:
                Just to be 100% sure: bridging is the way to do it? Or even the only way? Or maybe the easiest way? Are there other ways?

                Thank you
                Pete

                Pete
                Home: SG-2100 + UniFi + Synology. SG-1100 retired
                Parents: SG-1100 + UniFi + Synology
                Testing: SG-1100 w/ 120GB SSD via ext USB (eMMC dead). Works great

                1 Reply Last reply Reply Quote 0
                • AndyRHA Offline
                  AndyRH
                  last edited by

                  Same here, did it once to just learn a bit.
                  To my knowledge bridging is the only way, but smarter people may point out some other way.

                  o||||o
                  7100-1u

                  1 Reply Last reply Reply Quote 0
                  • First post
                    Last post
                  Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.