Why not try our Mail Server or FTP Server

 

Step 5: DNS Setup
This page explains how to set up your DNS to make your domain name relate to your IP address.


DNS and IPs
With most domain purchases, the registrar offers a DNS service in with the package. You must make sure that your domain name uses your registrar's DNS and you need to make sure the DNS contains the correct IP address of the computer running the services. Once this is done and all set up, eventually your domain will convert into your servers IP (it may take up to 36 hours to update). The DNS may also offer other facilities such as multiple sub-domains (code-crafters.com is the domain name, www.code-crafters.com is a sub-domain, mail.code-crafters.com is another sub-domain... etc.). Each of these sub-domains can also have its own set DNS information (such as the IP, MX records... Esc), which can be useful for load sharing and backup facilities.


MX Records
To make emails for your domain to be directed to your computer (if you're running your own Mail Server), you must set the MX records of the DNS to contain the host address of your Mail Server. If required, you can set more than one MX record and prioritize them accordingly. For example you could use:

mail.code-crafters.com - priority 5 (primary server)
mail2.code-crafters.com - priority 10 (secondary server)
mail3.code-crafters.com - priority 15 (ternary server)

The lowest priority value is used first and if this doesn't respond then the next lowest value is used. This continues until either one of the domains has responded or all of them have failed. This system allows you to run backup servers or even share the load with multiple servers.


Dynamic IPs
If your IP is not static then your IP may change occasionally, meaning that the domain name will no longer translate to the correct IP. It is therefore important to ensure that your DNS is kept up to date and also allows the updates take effect quickly. Most registrars are designed for static IP use so you may have to pay for another DNS service. A company called No-IP provides an excellent service which also provides you with a piece of software called 'Dynamic Update Client'. This client automatically monitors your IP and if a change occurs, it automatically updates the DNS.