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

    Replacing unifi usg pro 4 with pfsense vlan issue

    Scheduled Pinned Locked Moved L2/Switching/VLANs
    7 Posts 2 Posters 451 Views
    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.
    • K
      kdy1968
      last edited by

      I currently have a unifi network, consisting of a usg pro 4 router, unifi poe 16 port switch, unifi 6 lite access pointi have 2 vlans setup, 10 cams, and 20 is for iot, which work fine, I am trying to replace the usg router with pf sense...I am having issues with the vlans pulling correct ip subnets, they pull from the default network, 192.168.1.1.... on pfsense, I have created 2 vlans, vlan id 10, is cams, and vlan id 20 is IOT, each vlan was assigned interface, as well as set up on DHCP server, cams subnet is 192.168.10.1, and iot is 192.168.20.1... if I assign a port to iot vlan and connect a device, it wont pull 192.168.20.x address instead, instead pulls 192.168.1.x...from that device I can ping both vlan gateways, 192.168.20.1 and 192.168.10.1.

      I don't understand how the device would to connect to the appropriate DHCP server, is it like this , device connects to port, traffic from device is not tagged, hits port is tagged with vlan id of 20 for iot, the router see vlan id and routes to appropriate DHCP server..
      Not sure where things are going wrong..

      keyserK 1 Reply Last reply Reply Quote 0
      • keyserK
        keyser Rebel Alliance @kdy1968
        last edited by

        @kdy1968 Your issue is not tagging the additional VLANs (10 + 20) correctly on the pfSense downlink and the switch uplink. That might include the switch downlinks to AP’s as well.

        In reality you have a “shortcut” where VLAN 10 and 20 are untagged linked to the default VLAN, and thus both see the DHCP server in that VLAN instead.

        The fact that you can ping 192.168.10.1 and 20.1 says nothing about the wrong VLAN tagging. That is just pfsense that allows pings (are you using default allow all traffic rule?) recieved from one client in the 192.168.1.x network to the other interface addresses.

        Love the no fuss of using the official appliances :-)

        K 1 Reply Last reply Reply Quote 0
        • K
          kdy1968 @keyser
          last edited by

          @keyser thanks for the response, yes im using the default allow all firewall rules, to simply things, i will just work with one vlan iot, which i want a computer attached to port 10 to connect to...
          pfsense itself is installed on a minpc with two ports, wan goes to cable modem and lan goes to switch on port 16

          this is settings for port 10 on which computer connecting to this should be on vlan 20
          decd999f-575c-47b6-aab7-c3e3615a44f3-image.png
          this is the setting for iot network:
          e753ee7d-a722-4d0e-98da-7372914145c8-image.png

          port 16 is uplink port to pfsense:
          f3aaa044-c900-4abc-a17c-1ab5ad6e78c1-image.png

          on the pfsense router i created the vlan id...
          565024fc-0685-4eed-972f-2ec3de8d9b66-image.png

          i assigned to a interface, gave it a static ip of 192.168.20.1/24
          d18c6eb3-f721-4d1f-a30d-58afb5c2117d-image.png
          configured dhcp:
          db606821-c99e-4d0c-ab9e-763372910575-image.png

          firewall rule is set to allow all
          0428926e-cef8-44f6-919d-f39a6cf264c2-image.png
          lan rules are default
          5a8034b4-0ebd-41a3-82df-046d0af80d05-image.png

          happen to see what i might be missing

          keyserK 1 Reply Last reply Reply Quote 0
          • keyserK
            keyser Rebel Alliance @kdy1968
            last edited by keyser

            @kdy1968 I’m not very familiar with Unifi products, but your config does seem to be correct.
            However - depending on the client OS on computer your issue might be that you are allowing the other VLAN’s (tagged) on switch interface 10 where the client is connected. That will cause the client to see all broadcasts in the other VLANs (tagged), and I have has many issues with different client OS’es that then still select the PVID marked VLAN in the switch as default.
            Make sure to disable “trunking” on port 10, and set it to Access Vlan 20 only.

            Love the no fuss of using the official appliances :-)

            K 2 Replies Last reply Reply Quote 0
            • K
              kdy1968 @keyser
              last edited by

              @keyser seems like pfense suricata was some how bugged, i turned it off and everything started working turned it back on and everything is still working

              1 Reply Last reply Reply Quote 1
              • K
                kdy1968 @keyser
                last edited by

                actually its not working, appears to be a bug with suricata/netmap that breaks vlans, by remove the tag

                K 1 Reply Last reply Reply Quote 0
                • K
                  kdy1968 @kdy1968
                  last edited by

                  running the following on pfsense shell ifconfig igb0 -vlanhwtag -vlanhwcsum -vlanhwfilter in shell will allow me run run suricata in inline mode, and vlan will still work....you can use the app shellcmd to automatically run the cmd at boot..

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