4

I recently setup a subdomain on my clients web server. Here is the vhost setup:

Listen *:80

#primary domain
<VirtualHost *:80>
    # rails public folder
    DocumentRoot /u1/thisdomain.com/public
    ServerName thisdomain.com
    RailsEnv production
</VirtualHost>

#my subdomain
<VirtualHost *>
        ServerName dev.thisdomain.com
        DocumentRoot /u1/dev.thisdomain.com/public
</VirtualHost>

I don't get any apache config errors when doing a configtest. I gracefully restart apache. I threw a basic index.html in the subdomain document root.

Now when I try to access the subdomain I get:

In Chrome:

The webpage is not available. Error 101 (net::ERR_CONNECTION_RESET): Unknown error.

In Firefox:

The connection was reset

The connection to the server was reset while the page was loading.
 *The site could be temporarily unavailable or too busy. Try again in a few moments.
 *If you are unable to load any pages, check your computer's network connection.
 *If your computer or network is protected by a firewall or proxy, make sure that Firefox is permitted to access the Web.

I can access the normal thisdomain.com without issue and any other website out there without issue. I am not behind any sort of proxy. No special web connection setup. Just a normal cable modem with my cable ISP.

My subdomain document root has the same user and group ownership (as well as its subdirs) as the normal domain document root.

Also, I don't see anything show up in the error or access logs.

Where should I start to determine the problem here?

1 Answer 1

5

Do thisdomain.com and dev.thisdomain.com resolve to the same IP address in DNS?

Also, the NameVirtualHost address should match both VirtualHost addresses, i.e:

NameVirtualHost *:80

<VirtualHost *:80>
  ServerName thisdomain.com
  # ...
</VirtualHost>

<VirtualHost *:80>
  ServerName dev.thisdomain.com
  # ...
</VirtualHost>
1
  • Wow I feel really dumb for not checking that. They did in fact point to different IP addresses, which lead me to the conclusion that my client has a specific server already setup for dev.thisdomain.com. So upon randomly picking a completely different word instead of dev for my subdomain, it worked. Thanks! Nov 21, 2009 at 19:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .