PostCast SMTP Server
Home Buy Download Details Support

DNS Caching

Table of Contents

Every time your web browser wants to load a web page, it needs to contact a DNS server first, which will translate the address into a machine readable format - the IP address. The same thing happens when PostCast Server tries to send a message to a recipient. The domain name in the e-mail address is translated into the address of the server that receives messages for that domain. If for some reason, PostCast Server or any other program on your computer is unable to contact the DNS server, you will not be able to view the web page, send a message, or do anything on the Internet.

DNS Caching

Even though the communication only takes up a few hundred milliseconds each time a message is sent, these can add up over time, as the number of requests can easily reach hundreds or thousands of DNS queries. DNS servers can sometimes be unavailable and the responses to queries can be very slow.

An easy way to speed up this process is to cache the information locally thereby eliminating the need for repetitive queries to the remote DNS server. This is done by telling PostCast Server to contact a local database on your computer, rather than the remote DNS server. This local connection can be performed much faster and does not depend on the response time of the remote DNS server across the Internet.

PostCast Server contacts the remote DNS server once, and then caches (memorizes) the addresses returned from the query. So the next time you are requesting the same address, it instantly returns the answer, without having to contact your ISP's DNS server to ask it for the translation. The process is much faster, since it does not have to connect to any remote servers every time.

Basically, the logic behind the DNS cache feature is to include both bad and good domains in the list and use the ?Valid? column to mark them as valid. The domain is considered bad only if DNS server returns the ?Unresolved? error, which means that the DNS entry for that domain does not exist.

MX Records

PostCast Server requires an MX record for each domain it needs to send messages to. MX records specify that e-mail sent to a domain is handled by another machine.  

For example, we want the machine to handle the mail sent to All we need to do is have an MX for pointing to, then we tell the machine that it handles mail for, otherwise it will reject it. All the SMTP servers out there will now connect to to deliver mail to

Backup MXes and MX Priority

The purpose of MXes does not end there; it is also possible to have multiple MX records. In our simple example, we omitted to mention that MX records all have a preference assigned to them. For example, the MX saying that mail to goes to has preference 20. There is a second MX with preference 50 saying that mail to should go to

When there are multiple MX records, remote mail servers will first try to deliver mail to the server with the lowest preference. That means that if a mail server wants to send mail to, it looks up the MXes. It sees the one with preference 20 is the lowest one, it tries to connect to If doesn't respond, then it will look for the next-lowest preference MX, namely the one with preference 50, and thus connect to is a machine outside our main network, so even if our entire main network was experiencing problems, it would probably still be up. In this case, would be a backup MX.

DNS Caching Dialog Box

Use the DNS Caching dialog box to configure the caching interval and to manually modify the cached MX records. You can also create new MX records for domains by pressing the "Add" button and specifying MX servers and their priorities.

DNS entries never expire

Select this option if you do not want to refresh DNS information for domains. This is useful because it speeds up creating and maintaining  DNS cache database, but the DNS entries may become obsolete if MX records for some domain change. If that happens, the program will not be able to connect to the server that handles the incoming e-mail for the recipient.

Expire after

This option forces the program to regularly get the latest MX records for a domain from the DNS server. You can specify the reoccurrence interval and configure the program to refresh its database in certain number of days, weeks, or months.

Domain name is valid

This indicates whether the domain name has valid DNS records. If the DNS server returned an error after querying the data, the domain will be automatically marked as invalid. You can use this option to change this setting.


This column contains the addresses of servers that accept e-mail messages for the domain.


Determines the priority of this mail server. The less the number the higher the priority (0 means the highest priority, 65535 - the lowest). Thus, mail servers with lower priorities are regarded as secondary and will be used only if all mail servers with higher priorities are inaccessible or out of order for some reasons.

Home | Buy | Download | Details | Support

2019 Oricsoft, Inc. All rights reserved. | Privacy Statement