logo
Apache Lounge
Webmasters

 

About Forum Index Downloads Search Register Log in RSS X


Keep Server Online

If you find the Apache Lounge, the downloads and overall help useful, please express your satisfaction with a donation.

or

Bitcoin

A donation makes a contribution towards the costs, the time and effort that's going in this site and building.

Thank You! Steffen

Your donations will help to keep this site alive and well, and continuing building binaries. Apache Lounge is not sponsored.
Post new topic   Forum Index -> Apache View previous topic :: View next topic
Reply to topic   Topic: apache virtual host problem
Author
dontommy



Joined: 31 May 2014
Posts: 2
Location: Denmark

PostPosted: Sat 31 May '14 23:07    Post subject: apache virtual host problem Reply with quote

Hey

I am trying to set up domains and subdomains, on my webserver, however the domains are resolving, but when accessing a subdomain I get a 500 internal server error, permissions on files are the same on both domain and sub domain level


My virtual host files looks like this for domains and for the subdomains, and I am using Apache 2.4.7, on an ubuntu 14.04 running on a rackspace cloud server.


Domains:

<virtualhost *:80>
ServerAdmin mail@mail.mail
ServerName domain.com
ServerAlias www.domain.com


DirectoryIndex index.html index.php
DocumentRoot /home/user/domain.com/


<Directory /home/user/domain.com/>
DirectoryIndex index.php
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
</virtualhost>


Subdomains:


<virtualhost *:80>
ServerAdmin mail@mail.mail
ServerName sub.dabagroup.com
ServerAlias sub.dabagroup.com


DirectoryIndex index.html index.php
DocumentRoot /home/user/domain.com/subdomains/sub/


<Directory /home/user/domain.com/subdomains/sub/>
DirectoryIndex index.php
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
</virtualhost>

Anybody got an idea why it works on domains, and not the subdomains?

Thanks!
Back to top
dontommy



Joined: 31 May 2014
Posts: 2
Location: Denmark

PostPosted: Sun 01 Jun '14 8:23    Post subject: Reply with quote

Nevermind, found the problem.

I had the subdomains hosted on another server, and forgot to enable mod rewrite on that, therefore the 500 error...
Back to top


Reply to topic   Topic: apache virtual host problem View previous topic :: View next topic
Post new topic   Forum Index -> Apache