| Trouble shooting DNS-related issues is a common | | | | entry can be set up for domain.info. Then any |
| challenge for web developers who may just have | | | | subdomain will point to the IP of choice (your VPS |
| been exposed to challenges with code and databases | | | | for example). |
| before. If you set up domains on a dedicated server | | | | To reiterate, when you type in subdomain.domain.info |
| or a VPS for the first time and facing challenges the | | | | your machine will first find the name servers for |
| following will help. | | | | domain.info, then look up the hostname at that name |
| 1) Name servers are set for a domain at the domain | | | | server, retrieve the server IP, and now to the final |
| name registrar. To see which name servers are set | | | | step: how will the server know which directory on |
| for a domain check (or any other whois service). For | | | | the server to point the user to? |
| example the domain domain.info may return the | | | | 3) In case of a Linux web server, the httpd.conf file |
| Rackspace name servers dns1 and | | | | (located in /etc/httpd/conf) tells the web server |
| dns2.stabletransit.net. | | | | where on the server that the website can be found. |
| 2) At the name server proper DNS entries must be | | | | This file will contain a number of "virtual hosts". It's |
| set up. An "A entry", which is usually set up for a | | | | called virtual because many hosts can be assigned to |
| hostname, will have fields such as name and IP. An | | | | the same IP (long time back this was not possible in |
| example is subdomain.domain.info as name and | | | | web server software, but each hostname needed a |
| 174.143.155.XX as IP. The IP is the server IP. You can | | | | separate IP). Each virtual host directive will tell the |
| trouble shoot this using: zoneedit.com/lookup.html (if | | | | web server where to load files from for a particular |
| you run linux you can also use the nslookup | | | | host name (ServerName or alias). |
| command). | | | | These virtual host directives are created |
| Name server entries are set up at the name server. | | | | automatically when creating an account in WHM, |
| In the case of certain web hosting companies such | | | | adding a parked or add-on domain. You can trouble |
| as iweb.ca the name server is hosted on the same | | | | shoot this by viewing the httpd.conf file through SSH |
| server as the web server so whenever an account is | | | | (pico /etc/httpd/httpd.conf) and looking up the |
| created in WHM the DNS entries are automatically | | | | server name or alias. |
| set up. In the case of Rackspace the DNS is hosted | | | | Conclusion: If the files you put into a folder does not |
| separately so we need to manually set up a DNS | | | | show up when accessing a domain name its very |
| entry in their name server. To avoid having to set up | | | | likely there's a problem in any of the above three |
| many entries for each subdomain such as | | | | steps. In such a case just use the trouble shoot |
| abc.domain.info, def.lbclients.info and so on, a wildcard | | | | options described above. |