subdomains

eabrownell

Verified User
Joined
Mar 11, 2004
Messages
5
I have created a couple subdomains but I can not access them over the internet. I have created sub.domain.com and when I go to a browser and type in http://www.sub.domain.com I get a

The page cannot be displayed

If I type in http://www.domain.com/sub I get:

Forbidden
You don't have permission to access /reseller/ on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.


--------------------------------------------------------------------------------

Apache/1.3.29 Server at bcwdiv.com Port 80

I am sure I am not doing something simple but I don't know what it is...

Thank you!
 
Check the permissions on your public_html directory. Try setting it to 755 if it's not already. Same goes for public_html/sub

Also make sure that you've created an index.html file (or index.php..etc)

John
 
It's possible that the subdomain hasn't resolved yet, or named wasn't reloaded. If you post the subdomain and domain we can test it out for you to see if it's a propogation issue, or if named wasn't restarted.

John
 
Your nameservers are hosted on your registrar. You need to ether change nameservers to your server or you need to manually add subdomain at your registrar.
 
Seth said:
Actually, Seth, you're having a completely different problem.

Your awstats isn't available as a directory through either URL (here's what I get when I try http://e-vids.com/awstats/):
You don't have permission to access /awstats/ on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
So it appears that your problem is with your awstats setup.

Jeff
 
eabrownell's problem is with DNS.

Your DNS works.

Your problem appears to be that these aren't properly setup subdomains; if they were, then:

http://e-vids.com/test

and

http://e-vids.com/test2

would both work, because the subdirectories are automatically created when the subdomain is created.

Did you create these as subdomains or as domains?

If as subdomains, then check to see if you've got test and test2 directories in the e-vids.com public_html folder. If so, then check the permissions; you've got to get the directories working before subdomains will work.

If as domains, then check to make sure the directories and paths are properly set up on your server, and that the httpd.conf include file was properly created.

Jeff
 
I set these up as 'subdomains' from webadmins user panel.

The directories are there. And permissions apear to be correct. I have tried changing the permissions of the directories with no luck.
 
Last edited:
What is "webadmins"?

DirectAdmin will not work in conjunction with any other panel.

Do you have and index.html file in these directories?

You might want to post your directory listing in detail, using

ls -al

for each of the directories you're having a problem with.

Note that I won't be responding in a timely manner if at all; I'm leaving for vacation.

Jeff
 
webadmins = webadmin's
isn't the primary account the WEBADMIN?

i'll figure it out
 
Subdomains not working

Your correct eabrownell, subdomains definately need looking
at ... We just purchased DA, and found this thread after having
the EXACT same problem your having.

We were trying to add a subdomain called billing, so we
would have billing.domainname.com, but found some insteresting
results from DA.

1. DA added www.billing as an A record, rather than just billing
(Personally don't think adding in A records is really necessary,
maybe just adding a wildcard " * " A record would work fine
over modifying zone files on for subdomains. (In most cases)

2. DA installed the a directory called billing in a directory called
private_html with a temporary homepage. Not sure why it
added the directory there? Will add a few more subdomains
in my setup purely for testing this function to see why this
happens.

It did take about 10 minutes for domainname.com/billing to work
however billing.domainname.com still not functioning.

In any case, something is wrong. Not sure what as of yet.


-- Kevin Kwasnik
 
Hello,

DA adds both www.sub and sub for sub.domain.com. Many people were requesting the ability to access www.sub.domain.com. We did have wildcards setup previously, but it was requested to have it removed. Now you can add wildcards to new domains if you wish by simply adding

*=|IP|

to the /usr/local/directadmin/data/templates/custom/dns_a.conf after copying it from /usr/local/directadmin/data/templates/dns_a.conf

The "sub" directory is added to both the public_html and private_html directories so that you have have http://sub.domain.com and https://sub.domain.com . Many people only want it to be secure (ie billing.domain.com) so you can just add a redirect from the http location.

If you use your ISP's nameservers and try to access a new subdomain before named has reloaded (up to 1 minute after creation), then the ISP will assume it still won't be working 1 minute after you've created it so will return the cached "non-existant" result until the dns TTL expires (time to live). A wildcard would solve that either way, but you'll just need to wait until the new value propogates to your ISPs nameserver.

John
 
Back
Top