Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

ddragas

macrumors newbie
Original poster
Nov 30, 2013
1
0
Hi all

I've got problem on apache server. Problem manifests when virtual hosts file is included in apache configuration.

If I remove include of virtual hosts file apache returns words "It works!"

First I had symlink on path /www and real path is on another drive. Configuration did not work.

Later I've removed symlink ad still no success.

If virtual hosts file is included I get blank page and nothing is written apache in logs

this is configuration of virtual host I've used on 10.6.7 and it worked without problems.

Code:
<VirtualHost *:80>
    DocumentRoot "/www/mysite"
    ServerName domain.local
    ErrorLog "/private/var/log/apache2/mysite.local-error_log"
    CustomLog "/private/var/log/apache2/mysite.local-access_log" common
	<Directory /www/mysite>
		allow from all
		Options +Indexes
	</Directory>    
</VirtualHost>

Please help me to get this working.

Thank you in advance

Kind regards

ddragas
 
Why is servername set to domain.local?

My vhost config looks like this:
Code:
<VirtualHost *:80>
    ServerName example.com
    ServerAlias www.example.com
    DocumentRoot /var/www/example.com
    <Directory /var/www/example.com>
        AllowOverride all
    </Directory>
</VirtualHost>

Also, is that directory /www/mysite readable for the server? And can the server write to its logs? Turn up the logging output by changing the LogLevel parameter:
http://httpd.apache.org/docs/2.2/mod/core.html#loglevel
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.