Difference between revisions of "DNS Info"

From TheBestLinux.com
Jump to navigation Jump to search
 
(8 intermediate revisions by the same user not shown)
Line 1: Line 1:
RCModelHelis.com DNS Info for GoDaddy.com DNS Server Setup Configuration
+
= '''DNS - Domain Name Server''' =
 +
DNS is a system used to find computers on the internet and in private networks. The most common DNS server is the UNIX/Linux BIND8 & BIND9 NAMED(Named Daemon) package. Microsoft and other companies also make their own proprietary DNS server packages as well.
 +
 
 +
== '''Query DNS Server Records - Find an IP address or hostname''' ==
 +
There are a number of tools which can be used to query information from DNS servers.  The two most common command-line DNS tools are DIG and NSLOOKUP.
 +
 
 +
=== '''DIG''' ===
 +
Dig is a simple command used to query DNS server records, either by supplying the FQDN(Fully Qualified Domain Name - such as "www.dawgland.com", into a numeric IP address, such as "73.42.198.249".  This basic main IP address is known as a type A DNS server record, as it's IP version 4, which consists of 4 numbers separatedd by 3 dots. Less used currently are IPv6(IP version 6) records, known as AAAA DNS server records. Other DNS server record types are CN, which stands for "Common Name", which are aliases to actual hostnames, such as "mail" pointing to the IP address of the hostname "mail.domainname.com", and MX records,used to indicate actual email servers.
 +
 
 +
Here are some examples of how to use the dig command:
 +
Query a standard A hostname DNS record:
 +
<pre style="color:blue">
 +
[jamie@server.dawgland.com:~]$ dig A jrcomputers.net +short
 +
213.255.247.82
 +
[jamie@server.dawgland.com:~]$
 +
</pre>
 +
<br /><br />
 +
Query an Email Server's DNS record:
 +
<pre style="color:blue">
 +
[jamie@server.dawgland.com:~]$ dig MX jrcomputers.net +short
 +
0 mail.jrcomputers.net.
 +
[jamie@server.dawgland.com:~]$
 +
</pre>
 +
<br /><br />
 +
Perform a Reverse-DNS(rDNS) query/lookup:
 +
<pre style="color:blue">
 +
[jamie@server.dawgland.com:~]$ dig -x 213.255.247.82 +short
 +
mail.jrcomputers.net.
 +
[jamie@server.dawgland.com:~]$
 +
</pre>
 +
<br /><br />
 +
 
 +
== Email DNS MX Record Setup Example Using RCModelHelis.com DNS Info for GoDaddy.com DNS Server Setup Configuration ==
  
 
Steps to setup the Email MX DNS record allowing mail to flow to the server:
 
Steps to setup the Email MX DNS record allowing mail to flow to the server:
(Using My New VM Host vm1.rcmodelhelis.com being hosted on BudgetVM.com)
+
(Using My New VM Host vm1.rcmodelhelis.com)
  
For all 3 steps below, set TTL(Time To Live) to 600 seconds:
+
For all 3 steps below, set TTL(Time To Live) to 600 seconds<br />
For all 3 steps below, do NOT include the quotes in the examples:
+
and DO NOT include the quotes in the examples:
  
<li>Create DNS "A" Redord "vm1" points to IP "198.56.248.58"
+
<li>Create DNS "A" Redord "vm1" which points to IP "198.56.248.58"
<li>Create DNS "CName" Alias Redord "mail" points to "vm1.rcmodelhelis.com"
+
<li>Create DNS "CName" Alias Redord "mail" which points to "vm1.rcmodelhelis.com"
<li>Create DNS "MX" Record "@" points to "mail.rcmodelhelis.com"
+
<li>Create DNS "MX" Record "@" which points to "mail.rcmodelhelis.com"
 
with Highest Priority set to "0" (Lower number = higher priority)
 
with Highest Priority set to "0" (Lower number = higher priority)
 
<br /><br />
 
<br /><br />
Line 17: Line 49:
 
<br />
 
<br />
  
Check and Test Your MX Record Setup/Configuration from the command line:
+
Check and test your MX record setup/configuration from the command line on your new email server:
 
<br />
 
<br />
dig +short A $(dig +short MX example.com | head -1 | cut -d' ' -f2)
+
<pre style="color:blue">
<br /><br />
+
dig +short A $(dig +short MX rcmodelhelis.com | head -1 | cut -d' ' -f2)
If the result of this command is the IP address of your server, you're good.<br />  
+
</pre>
If not, check your MX records in your domain DNS zone; and make sure you have waited long enough for the changes to spread.<br />  
+
<br />
 +
Or:
 +
<br />
 +
<pre style="color:blue">
 +
[jamie@fc36.dawgland.com:~]$ host -t MX linuxjamie.com
 +
linuxjamie.com mail is handled by 0 linuxjamie-com.mail.protection.outlook.com.
 +
</pre>
 +
<br />
 +
If the result of this command is the IP address of your server, you are good to go!.<br />  
 +
If it is not, check the MX records of your domain DNS zone.  Also, be sure you have waited long enough for the changes to spread through the internet.<br />  
 
This can take up to 24 hours. Also make sure your /etc/resolv.conf file is listing valid DNS servers.
 
This can take up to 24 hours. Also make sure your /etc/resolv.conf file is listing valid DNS servers.

Latest revision as of 10:48, 12 September 2023

DNS - Domain Name Server

DNS is a system used to find computers on the internet and in private networks. The most common DNS server is the UNIX/Linux BIND8 & BIND9 NAMED(Named Daemon) package. Microsoft and other companies also make their own proprietary DNS server packages as well.

Query DNS Server Records - Find an IP address or hostname

There are a number of tools which can be used to query information from DNS servers. The two most common command-line DNS tools are DIG and NSLOOKUP.

DIG

Dig is a simple command used to query DNS server records, either by supplying the FQDN(Fully Qualified Domain Name - such as "www.dawgland.com", into a numeric IP address, such as "73.42.198.249". This basic main IP address is known as a type A DNS server record, as it's IP version 4, which consists of 4 numbers separatedd by 3 dots. Less used currently are IPv6(IP version 6) records, known as AAAA DNS server records. Other DNS server record types are CN, which stands for "Common Name", which are aliases to actual hostnames, such as "mail" pointing to the IP address of the hostname "mail.domainname.com", and MX records,used to indicate actual email servers.

Here are some examples of how to use the dig command: Query a standard A hostname DNS record:

[jamie@server.dawgland.com:~]$ dig A jrcomputers.net +short
213.255.247.82
[jamie@server.dawgland.com:~]$



Query an Email Server's DNS record:

[jamie@server.dawgland.com:~]$ dig MX jrcomputers.net +short
0 mail.jrcomputers.net.
[jamie@server.dawgland.com:~]$



Perform a Reverse-DNS(rDNS) query/lookup:

[jamie@server.dawgland.com:~]$ dig -x 213.255.247.82 +short
mail.jrcomputers.net.
[jamie@server.dawgland.com:~]$



Email DNS MX Record Setup Example Using RCModelHelis.com DNS Info for GoDaddy.com DNS Server Setup Configuration

Steps to setup the Email MX DNS record allowing mail to flow to the server: (Using My New VM Host vm1.rcmodelhelis.com)

For all 3 steps below, set TTL(Time To Live) to 600 seconds
and DO NOT include the quotes in the examples:

  • Create DNS "A" Redord "vm1" which points to IP "198.56.248.58"
  • Create DNS "CName" Alias Redord "mail" which points to "vm1.rcmodelhelis.com"
  • Create DNS "MX" Record "@" which points to "mail.rcmodelhelis.com" with Highest Priority set to "0" (Lower number = higher priority)

    Save all DNS redords for changes to take effect, which is usually instant from past experience with the above examples. Others may take longer.

    Check and test your MX record setup/configuration from the command line on your new email server:
    dig +short A $(dig +short MX rcmodelhelis.com | head -1 | cut -d' ' -f2)
    


    Or:

    [jamie@fc36.dawgland.com:~]$ host -t MX linuxjamie.com
    linuxjamie.com mail is handled by 0 linuxjamie-com.mail.protection.outlook.com.
    


    If the result of this command is the IP address of your server, you are good to go!.
    If it is not, check the MX records of your domain DNS zone. Also, be sure you have waited long enough for the changes to spread through the internet.
    This can take up to 24 hours. Also make sure your /etc/resolv.conf file is listing valid DNS servers.