My subdomains on hostgator are not working
Asked Answered
I

3

6

We are hosting our primary domain on HostGator, and we've recently created sub-domains on the primary domain with the following format: SubDomainName.PrimarySiteName.com

I can open the sub-domain files through the cPanel, and the folder that each sub-domain should take content from is correct. But when we try to open the sub-domains in the browser, we get the following error: "Server not found". It has been more than a month for now from the time we created the sub-domains. Also, sub-domains will sometimes open on one computer, but not another.

Inger answered 21/6, 2012 at 11:57 Comment(10)
Have you set up the DNS for the subdomains?Kershaw
no, how and where to set DNS for subdomains ?Inger
Some DNS in the world is responsible for resolving "www.domain.tld" to the IP address of your server. You have to configure it to do the same for "forum.domain.tld". The "How" depends on your DNS providerKershaw
so this configuration should be done from the control panel ? i don't really get it.sorry i am new to this. i have only "Advanced DNS Zone Editor" related to DNS in the Control Panel, and subdomains are lised with TTL ,Class ,Type ,Record . can u give me an example depending on any DNS provider so that i can know what u're talking about ?Inger
Try Class inet, Type A, Record "forum.domain.tld" Value=The IP-Address of your serverKershaw
They are already chosen that way :(Inger
run "ping www.domain.tld" and "ping forum.domain.tld" and compare the outputKershaw
pinging the domain shows reply from ip, whereas pinging sub domain gives "Ping request couldn't find host ... " .Thanks for ur repliesInger
This validates, that you have a DNS problem. There is no such thing as a "universal guide to DNS", this depends heavily on your provider(s).Kershaw
Yes, I do believe it was caused by DNS problem. Please kindly check it or you can contact HostGator team.Runin
T
17

Using the CPanel for your account with Host Gator simply click on "Simple DNS Zone Editor" and then finally ADD an "A Name" for the sub domain. Your "A Name" would be your complete sub domain URL. Example: subdomain.yourmaindomain.com AND than add the IP address for your main domain.

I had this issue and was able to resolve it by simply adding the single A Name record.

Turtle answered 12/3, 2015 at 1:11 Comment(0)
E
1

Once you create your subdomain, the DNS records are normally created for you by your host. Most likely, you'd need to wait just a few hours before the subdomain becomes available.

You can however access your subdomain in the meantime using one the following methods:

http://ipaddress/~username/subfolder/ -OR- http://servername/~username/subfolder/

Ethnology answered 23/1, 2016 at 15:44 Comment(1)
This answer ignores the fact that they have been working on this problem for a month... :PScriptwriter
W
0

There is an error in the Hostgator documentation for this.

If you are using Hostgator for DNS it automatically sets up the DNS completely for new subdomains when you use the create subdomain command in cpanel. You do not even have to use Hostgator as your registrar, as long as the name server entries at your registrar point to your Hostgator name servers, which are the name servers shown on the Hostgator cpanel screen.

The documentation error involves the Document Root field to be filled out when using the cpanel create subdomain command, which is needed when the subdomain files are hosted in the same hostgator account as the main domain. In the hostgator documentation, the example for the document root is "/public_html/blog1" as an example place to put the files for a new subdomain "blog1". This is incorrect- the document root you enter for the new subdomain in the cpanel subdomain command must NOT start with a SLASH. Remove the slash and use "public_html/blog1" (or wherever you want to put your files within public_html) and it just works.

Also, there is no delay for this, as long as your main site has already been set up. When you enter the create subdomain command correctly, it gets entered into the hostgator DNS at that time, and the internet already has the hostgator name servers as the authoritative name servers for your domain name. So you don't have to wait a few days or even a few hours. Sometimes you have to flush your browser cache.

Good luck, and more subdomains to you!

Wigan answered 9/12, 2018 at 21:22 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.