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

    PfSense cannot resolve internal hostnames

    Scheduled Pinned Locked Moved DHCP and DNS
    4 Posts 3 Posters 6.2k 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.
    • C
      Cylindric
      last edited by

      Hi, folks.

      I'd like to use hostnames in aliases and rules, but it looks like DNS resolution from the pfSense box isn't picking up the default domain.

      The General settings for pf are a hostname of "firewall" and a domain "mydomain.co.uk" (which is our internal MS DNS domain name).

      If I try a DNS lookup in the diagnostics, I get a result for mycomputername.mydomain.co.uk, but not mycomputername.

      Is it possible to set things up so that a hostname-only gets resolved?

      DNS Forwarder is enabled. pfSense version is 2.1-RELEASE.

      1 Reply Last reply Reply Quote 0
      • D
        doktornotor Banned
        last edited by

        P.S. Why don't you use the proper FQDN in the first place?!

        1 Reply Last reply Reply Quote 0
        • C
          Cylindric
          last edited by

          That seems to indicate I'd have to put them all in /etc/hosts? I want pfSense to check my upstream DNS server, which is my internal DNS server.

          The reason I want to do this is so I don't have a rules/alias list full of redundant ".mydomain.com" all over the place. Seems sensible enough? Especially with the odd fixed-width design of the GUI - a short list of hostnames quickly becomes very long if you have to use FQDNs.

          1 Reply Last reply Reply Quote 0
          • M
            mitchtay
            last edited by

            @Cylindric:

            That seems to indicate I'd have to put them all in /etc/hosts? I want pfSense to check my upstream DNS server, which is my internal DNS server.

            The reason I want to do this is so I don't have a rules/alias list full of redundant ".mydomain.com" all over the place. Seems sensible enough? Especially with the odd fixed-width design of the GUI - a short list of hostnames quickly becomes very long if you have to use FQDNs.

            Have you checked the setting "Do not use the DNS Forwarder as a DNS server for the firewall" under System > General Setup?

            I just tried it with it both enabled and disabled on my firewall and when this setting is enabled my firewall is unable to resolve any internal hostnames at all (whether FQDN or not).
            Also have you entered an approriate domain entry under System > General Setup so that it is in the domain search list? If not then the hostname lookup will not know to append the domain when it gets an incomplete query.

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