How to setup Domain Name Server

Date March 7, 2010



First time when I try to setup for a domain I have some problems. For this reason this is a little step by step tutorial for how to setup .

First of all this setting is exactly for my case, for other situations, like another domain registrar or another host manager can be different.
Correct settings for involve two steps:
- setup in ()
- setup in domain registrar account, in that case godaddy.

Let’s proceed with first step, setup in ().

All my hosting plans and their options are managed through control panel manager interface (CPM) and hosting plans is set through (), and all is hosted in a virtual private server (VPS). First mistake was when I suppose so my virtual private server name must have the same name with . That was wrong. My virtual private server (VPS) name can be any another name, preferable to be the same or related with one of my domains registered by me through godaddy account.
Before set must have added hosting plan, domain name and user here in .

In Server Configuration go to

  • Main Shared Virtual Host IP and enter your IP: 99.999.999.999
  • Basic cPanel/ Setup enter your
    • Hostanme (ex: server.domain-name.com)
    • Primary Nameserver: ns1.domain-name.com
    • Secondary Nameserver: ns2.domain-name.com

In Networking Setup go to

  • Hostname the same like above: server.domain-name.com after confirm must update the certificate. For that, here, open in a new window everey “Manage Service Certificates” link and clik Reset Certificate/Generate a new Certificate.
  • Resolver Configuration – setting up your resolver configuration (/etc/resolv.conf).

With that mentions let’s go into (), straight “Add Zone” in “ Functions”.

Domain TTL Record type

1. domain-name.com       86400  IN SOA       ns1.domain-name.com. manager.server-manager.com.
1a. 1234567890            Serial Number
1b. 86400                         Refresh
1c. 7200                            Retry
1d. 1209600                     Expire
1e. 86400                           Minimum TTL

2. domain-name.com. 86400 IN NS ns1.domain-name.com.
3. domain-name.com. 86400 IN NS ns2.domain-name.com.
4. domain-name.com. 14400 IN A 99.999.999.999
5. localhost 14400 IN A 127.0.0.1
6. domain-name.com. 14400 IN MX 0 domain-name.com.
7. mail 14400 IN CNAME domain-name.com.
8. www 14400 IN CNAME domain-name.com.
9. ftp 14400 IN A 99.999.999.999
10. cpanel 14400 IN A 99.999.999.999
11. 14400 IN A 99.999.999.999
12. webmail 14400 IN A 99.999.999.999
13. webdisk 14400 IN A 99.999.999.999
14. ns1 14400 IN A 99.999.999.999
15. ns2 14400 IN A 99.999.999.999

where:
- domain-name.com – domain which is set right now
- 99.999.999.999 – IP address give by VPS manager
- 127.0.0.1 – an IP used by default than some software installed in VPS (like MySQL, php…)

You can see here, three columns:
Domain (this isn’t web domain name);
Time To Live (TTL) – is a stored time in seconds, for coresponding record ( domain, on the same line);
after that time record is refreshing;
Record Type -
SOA (Start of Authority) – here is set information about primary master server name (ns1.domain-name.com in that case), email of the administrator

The most commonly used record types are:

  • NS ()
  • A (address)
  • AAAA (adress) – AAAA record is to help transition and coexistence between IPv4 and IPv6 networks
  • MX (mail exchange)
  • CNAME (canonical name) – that records are domain name aliases; only a single node of the name space.
  • PTR(domain name pointer) – are primarily used as “reverse records” – to map IP addresses to domain names (reverse of A-records and AAAA-records).
  • TXT (Descriptive text) – They are often used to hold general information about a domain name such as who is hosting it, contact person, phone numbers, etc.

The following are all less commonly used:

  • DS (Delegation Signer) – refers to a DNSKEY RR by storing the key tag, the algorithm number, and a digest of the DNSKEY RR.
  • A6 (address) – A6 record is used to represent a 128-bit IPv6 address
  • AFSDB – that record maps a domain name to an AFS (Andrew File System) database server.
  • DNAME – that is used to map or rename an entire sub-tree of the name space to another domain.
    It differs from the CNAME-record which maps only a single node of the name space.
  • HINFO (Host information) – specifies the host / server’s type of CPU and operating system.
  • LOC (Location information) – is used to specify geographical location information about hosts, networks, and subnets.
  • NAPTR (Naming Authority Pointer) – are used to store rules used by DDDS (Dynamic Delegation Discovery System) applications.
  • RP (Responsible person) – specifies the mailbox of the person responsible for a host (domain name). A SOA-record defines the responsible person for an entire zone, but a zone may contain many individual hosts / domain names for which different people are responsible.
  • SRV (location of service) – are used to specify the location of a service. This record type is however NOT supported by most programs in use today, including web-browsers.

More informations about DS records here:
http://www2.rad.com/networks/applications/dns/dnssecrr.htm#_ds
More about records here:
http://www.simpledns.com/help/v52/index.html?rectypes.htm
More details about SOA here:
http://www.cadetech.co.uk/Web_Design_information/DNS.asp

Now, must add a A entry for your host name in Functions, Add an A Entry for your hostname.

Last step here, must go in your () in Networking Setup, Resolver Configuration and put here your two IP’s: 99.999.999.998 and 99.999.999.999.

DNS resolver configuration

resolver configuration

This will setting up your resolver configuration stored in /etc/resolv.conf. Or, you can manually edit this file in yours VPS. Without that settings I receive every 24 hours in my email box (even if A entry is already added):
——————-email———————————
Subject: [ipcheck] Problems with setup on server.domain-name.com
Body: MPORTANT: Do not ignore this email.
The hostname (server.domain-name.com) resolves to . It should resolve to 99.999.999.999. Please be sure to correct /etc/hosts as well as the ‘A’ entry in zone file for the domain.

Some are all of these problems can be caused by
/etc/resolv.conf being setup incorrectly. Please check this file if you
believe everything else is correct.

You may be able to
automatically correct this problem by using the ‘ Add an A entry for your
hostname ‘ under ‘ Functions ‘ in your
—————–end email———————————-

That is all in (). I repeat, that works for me with above settings.

Let’s proceed with second step, setup in account from domain registrar, in that case godaddy.

Here is more simple: login to your account go to Domains, My domains click on domain name and under Nameservers go to Change link and put in two boxes ns1.domain-name.com and ns2.domain-name.com.

This is necessary a short detail; if you have same error messages when try to change nameservers maybe is necessary to ad host summary. For that in domain detail page scroll down and click add on host summary and put in Host name -> ns1 and in Host IP1 ypor IP -> 99.999.999.999 and confirm.

After that, for match nameserver in / Networking Setup / Nameserver IP’s with your new must manual edit etc/namserverips file on VPS. Then restart your container.

That is it.

Last words: after all settings, in and domain registrar account must verify that settings. Go to intodns.com put your domain here and check if everything is ok. I use current intodns for check my settings, but bellow is more similar free tools.

http:///www.intodns.com
http://www.dnsqueries.com/en/
http://dnssy.com/
http://www.unifiedemail.net/Tools/Configuration/Default.aspx

I hope you find some useful information here and if you have any opinion or suggestion please leave a comment.

Tags: , , , ,
    Related posts:

    Leave a Reply

    XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>