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

    DHCP Server & DNS Resolver for Unselected Interface

    Scheduled Pinned Locked Moved DHCP and DNS
    3 Posts 2 Posters 618 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.
    • D Offline
      Double K
      last edited by

      Here's what I'm trying to do;
      On VLAN1, have DHCP clients use DNS Resolver for resolving DNS queries - success!
      On VLAN2, have DHCP clients use System DNS servers for resolving DNS queries - failure!

      DNS Resolver is enabled, and VLAN1 is selected in the Network Interfaces.  VLAN 2 is not selected.

      DHCP Server is enabled for both VLAN1 & VLAN2.  DNS server fields are blank in both.
      "Leave blank to use the system default DNS servers: this interface's IP if DNS Forwarder or Resolver is enabled, otherwise the servers configured on the System / General Setup page."

      My limited understanding is that DNS Resolver should not be "enabled" for VLAN2 if the Interface is not selected in the DNS Resolver configuration.  Thus, clients on VLAN2 should be using the servers configured in the System / General Setup page.  However, clients are instead receiving the local interface IP address as their DNS Server, and are failing (DNS Resolver operating as expected).  Thus, it appears the DHCP server is not operating as expected in terms of "should be" handing the System DNS servers to clients on VLAN2 when that interface is not selected/enabled in DNS Resolver.

      Can the members help me understand if I'm missing something, or if the DHCP server uses the Global DNS Resolver Enabled setting rather than the individual Interface selection setting?  Is this an improvement opportunity / feature request?

      PS - I know I can manually specify the DNS servers in the DHCP options for VLAN2 and achieve success.  I'm deliberately trying to pass the System DNS to see what would happen if I didn't configure the DNS servers in the DHCP options on a VLAN, and didn't select that VLAN's Interface in DNS Resolver.

      1 Reply Last reply Reply Quote 0
      • johnpozJ Offline
        johnpoz LAYER 8 Global Moderator
        last edited by

        What that means if your not running either forwarder or resolver then clients would get what you setup in the system.. IF your running forwarder or resolver.. Then your dhcp clients would point to pfsense for dns and use either the resolver or forwarder whichever which one your using.

        An intelligent man is sometimes forced to be drunk to spend time with his fools
        If you get confused: Listen to the Music Play
        Please don't Chat/PM me for help, unless mod related
        SG-4860 25.07.1 | Lab VMs 2.8.1, 25.07.1

        1 Reply Last reply Reply Quote 0
        • D Offline
          Double K
          last edited by

          Thanks @johnpoz - so that means that the DHCP server uses the Global "Enable DNS Resolver" or "Enable DNS Forwarder" rather than the individual Interface selection within those services.  Thus, the only way to pass the System DNS servers to clients when running DNS Resolver (or Forwarder) is to manually specify them in the DHCP Server options for the interface that you don't want to use DNS Resolver (or Forwarder) on.

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