5 Replies Latest reply: Jun 16, 2014 3:39 PM by Iggy Pelman
Iggy Pelman Level 1 Level 1 (20 points)

I use an external DNS that includes MX and mail entries and A records that point to a static IP provided by my ISP, stored in my router, that in turn accesses services on my lion server via port forwarding. The DNS service on my lion server was turned on but I turned it off and I'm not sure I've noticed any difference - I've got issues either way. Do I need it for any mail server related reason?


Mac mini, Mac OS X (10.7.3)
  • Camelot Level 8 Level 8 (46,395 points)

    Your mail server needs to be able to resolve hostnames both for clients that connect to it (e.g. clients on your LAN and remote servers sending mail to your domain), and to be able to find the mail servers for domains that you're sending mail to.

     

    That DNS server does not have to be on the mail server itself. It can be any other DNS server that will respond to lookups.


    Typically, though, you will need an internal LAN DNS server since neither your ISP nor any other upstream DNS server is going to know anything about your LAN addresses.

  • Iggy Pelman Level 1 Level 1 (20 points)

    Thank you for your reply.

     

    Does that role not fall upon my router through DHCP? And, if I do need the DNS should I open the DNS port on the router itself?

  • Antonio Rocco Level 6 Level 6 (10,375 points)

    Hi

     

    Where on your router can you configure DNS Records your private LAN is going to need?

     

    Simply for stability and robustness reasons (before you consider anything else) any Mac Server (going back to at least 10.5) is going to need something it can resolve its assigned hostname to. Unless you have a really expensive Router it's doubtful your Router can fulfill this role properly for your private LAN?

     

    HTH?

     

    Tony

  • Camelot Level 8 Level 8 (46,395 points)

    Does that role not fall upon my router through DHCP? And, if I do need the DNS should I open the DNS port on the router itself?

    There are two parts to your question, so I want to clarify a couple of points.

     

    There is no relationship between DHCP and DNS - just because your router is running DHCP for your network, that doesn't mean it's also doing DNS. It will tell the clients which DNS server to use, but that doesn't have to be the router.

     

    Even if your router has the ability to run as a DNS server that is usually limited to being a caching/proxy server for some other DNS server - in other words, your network clients query your router, your router then querieswhatever DNS server it is configured with (your ISP, Google DNS, OpenDNS, etc.) and passes back the result, usually caching that result so the next lookup for the same host happens quicker.

    This is very different from running as an actual DNS server for your LAN. This caching server knows nothing about your private LAN addresses (192.168.x.x, 10.x.x.x, etc.), nor does it know anything about hosts in your LAN (your servers, clients, printers, etc.) and will not be able to answer queries for these addresses/hosts. All it will do is proxy the connection to your upstream (who know nothing about your LAN).

     

    For that reason you should have your own DNS server in your LAN - a server that knows about your hosts and IP addresses in your network. Whether this server's address is the one handed out by DHCP, or whether the router continues to act as a DNS proxy pointing to your internal server doesn't really matter - the point is that hosts on the local network (including your server) can resolve hostnames and IP addresses on your LAN.

  • Iggy Pelman Level 1 Level 1 (20 points)

    The answer is "yes". You have to have a DNS running along with Open Directory and (probably) File Sharing. All your email recipients must be Local Network Users (as opposed to Local Users). See https://discussions.apple.com/message/26141304#26141304 for more sage advice on the subject.