Hey, folks! I had begun configuring VLANs recently, and I’ve got two managed switches between my firewall and my mini PC. I set up a 10 VLAN on the third octet with a /24 mask, and the idea is that anything on 10 should be able to reach the internet but not VLAN 1, while VLAN 1 should be able to access the internet and VLAN 10 services. I’m not so crazy as to try to start with that configuration though. No ports or anything are exposed yet, so my first test was just going to be full access between networks. I maybe counted my initial configuration as a success too soon, because with the mini PC on the 10 network, I can reach the gateway at 192.168.10.1 but nothing else. I can even access the OPNsense config page at the 10 gateway address. If I ping 192.168.1.1, I get “Network is unreachable”. If I ping www.google.com, I get “Temporary failure in name resolution”, and I also can’t pull up sites like YouTube. And again, this is all with a VLAN rule that I believed to be configured to allow all traffic, as it mimics what’s set up for my default LAN interface. Pinging the mini PC from the 1 VLAN also fails; it just sort of times out with 100% packet loss, so perhaps the default rule is less permissive than I thought, but it does say it allows all.

I’ve been following beginner guides from the Home Network Guy (a name that makes this stuff sound more approachable than how he actually presents it), but even with a video that’s not even 3 years old, pieces of OPNsense have been deprecated and replaced with new components such that I can’t follow along verbatim. For instance, it was an ordeal to get DHCP working now that the one he used has been replaced with Dnsmasque DNS and DHCP, and I can’t even tell you what I changed that eventually got it working, but my first couple of tries did not. In one of those videos I’ve been following, he indicates that the default rule on the LAN interface will allow full access between all networks, but that doesn’t seem to be the case, as the same settings on the other VLAN aren’t allowing them to talk to one another.

Obviously, I don’t intend to leave full access between the networks when it’s time to go live, but this simple smoke test shows that there’s a gap in my understanding if I can’t get what should be the easiest test to work. Does anyone know what I’m missing or what I should do to troubleshoot from here?

  • Archer@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    edit-2
    5 hours ago

    This is a great opportunity to learn tshoot on OPNsense. Learn where the firewall logs are and how to check them to see if your client IP is blocked. Check the firewall rules to see if that VLAN has internet access - remember, the default is deny on firewalls, so the one you made is not the default OPNsense “LAN” network with a rule allowing internet access, so look at how that is set up and compare to your VLAN

    • ampersandrew@lemmy.worldOP
      link
      fedilink
      English
      arrow-up
      1
      ·
      4 hours ago

      Looking at the live view, a ping against Google shows both my and Google’s IPv6 addresses when done from my desktop on VLAN 1, but the logs show nothing of the sort when done from my mini PC on VLAN 10, which isn’t surprising, since the error returned from the terminal is “Temporary failure in name resolution”, meaning the error is before it even knows what Google’s IP address is. I don’t know what step I might have missed for that to be the case.

      If you look at my screenshot, those are the settings of my VLAN’s firewall rule, and if there’s a difference between that and the one on the LAN interface, other than the field labeled Interface Name, I don’t know what it is. The LAN interface has a firewall rule for IPv6 as well, but the Home Network Guy tutorial skipped that one, and it still reached the internet. His tutorial was for allowing internet access without reaching the other private networks, but I believe I understand the Invert setting that he checked, and I did the opposite of that specifically for this test.

      • Archer@lemmy.world
        link
        fedilink
        English
        arrow-up
        1
        ·
        4 hours ago

        Interesting, try pinging 8.8.8.8 (no DNS dependency) and looking at your DNS settings, what DNS is set up for the host?

        • ampersandrew@lemmy.worldOP
          link
          fedilink
          English
          arrow-up
          1
          ·
          edit-2
          3 hours ago

          A ping against that address works on the VLAN 1 desktop. It returns “Network is unreachable” on VLAN 10. I’m not quite sure what you mean by DNS settings on the host. I’m using DHCP, and DNS appears to be automatic as well. I’m on Debian KDE, for what that’s worth, and historically in my life, I haven’t touched DNS settings basically anywhere; maybe I could count how many times I did on my fingers, but it definitely wasn’t recently for this project. Presumably the problem isn’t only DNS, because these two computers on different VLANs can’t ping each other by IPv4.

          • Archer@lemmy.world
            link
            fedilink
            English
            arrow-up
            1
            ·
            3 hours ago

            I need to see your firewall rules for both 1 and 10, dhcp settings for 10, and the output of ip addr on your test machine.

            • ampersandrew@lemmy.worldOP
              link
              fedilink
              English
              arrow-up
              1
              ·
              2 hours ago

              The screenshot in the original post is the only firewall rule on 10. This is the equivalent rule on 1 that will look very familiar.

              And this is the IPv6 rule on 1. Both of these screenshots were from rules set up by default.

              From the mini PC on VLAN 10, the output is:

              inet 192.168.10.157/24 brd 192.168.10.255 scope global dynamic noprefixroute

              • Archer@lemmy.world
                link
                fedilink
                English
                arrow-up
                1
                ·
                2 hours ago

                Try allowing IPv4 and IPv6, something really basic appears to be broken, so it makes sense to allow more until it’s figured out

                • ampersandrew@lemmy.worldOP
                  link
                  fedilink
                  English
                  arrow-up
                  1
                  ·
                  2 hours ago

                  I think I’ve adjusted it to be as permissible as possible. There are some auto-generated rules that populate above it that, when expanded, look like maybe they would interfere? But I thought the manual rules should override anything in there. I can’t think of anything else.