Hoppas detta är rätt ställe... annars får ni flytta denna tråd till rätt. ;)
Jag undrar hur man sätter upp en subdomän på en apache server...
Jag har lagt till förljande i min httpd-vhosts fil:
NameVirtualHost *:80
#This is the first VHOST for you content stoll.nu
#change the path to your pathes of content
<VirtualHost *:80>
ServerName stoll.nu
ServerAlias www.stoll.nu
ServerAdmin webmaster@stoll.nu
DocumentRoot C:/Program/xampp/htdocs/
<Directory "C:/Program/xampp/htdocs">
AllowOverride All
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
#This is the first SUBdomain with his own Path for content
<VirtualHost *:80>
ServerName sub1.stoll.nu
ServerAlias www.sub1.stoll.nu
ServerAdmin webmaster@stoll.nu
DocumentRoot C:/Program/xampp/htdocs/sub1stollnu/
<Directory "C:/Program/xampp/htdocs/sub1stollnu">
AllowOverride All
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
#This ist the next SUBdomain with own Path of content
<VirtualHost *:80>
ServerName sub2.stoll.nu
ServerAlias www.sub2.stoll.nu
ServerAdmin webmaster@stoll.nu
DocumentRoot C:/Program/xampp/htdocs/sub2stollnu/
<Directory "C:/Program/xampp/htdocs/sub1stollnu">
AllowOverride All
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
och så har jag tagit bort # framför Include conf/extra/httpd-vhosts.conf
men när jag har startat om servern så får jag Error 403 Access Denied när jag försöker att gå in på sidan?
min Errorlog ser ut så här:
[Wed Jun 14 15:33:59 2006] [notice] Apache/2.2.0 (Win32) DAV/2 mod_ssl/2.2.0 OpenSSL/0.9.8a mod_autoindex_color PHP/5.1.2 configured -- resuming normal operations
[Wed Jun 14 15:33:59 2006] [notice] Server built: Dec 1 2005 18:36:53
[Wed Jun 14 15:33:59 2006] [notice] Parent: Created child process 3140
[Wed Jun 14 15:34:00 2006] [notice] Child 3140: Child process is running
[Wed Jun 14 15:34:00 2006] [notice] Child 3140: Acquired the start mutex.
[Wed Jun 14 15:34:00 2006] [notice] Child 3140: Starting 250 worker threads.
[Wed Jun 14 15:34:00 2006] [notice] Child 3140: Starting thread to listen on port 443.
[Wed Jun 14 15:34:00 2006] [notice] Child 3140: Starting thread to listen on port 80.
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:02 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:03 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 15:34:03 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
Men sökvägen är inte fel... så vad är det som är fel?!
<VirtualHost *:80>
ServerName stoll.nu
ServerAlias www.stoll.nu
ServerAdmin webmaster@stoll.nu
DocumentRoot C:/Program/xampp/htdocs/
<Directory "C:/Program/xampp/htdocs">
AllowOverride All
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
#This is the first SUBdomain with his own Path for content
<VirtualHost *:80>
ServerName sub1.stoll.nu
ServerAlias www.sub1.stoll.nu
ServerAdmin webmaster@stoll.nu
DocumentRoot C:/Program/xampp/htdocs/sub1stollnu/
<Directory "C:/Program/xampp/htdocs/sub1stollnu">
AllowOverride All
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
#This ist the next SUBdomain with own Path of content
<VirtualHost *:80>
ServerName sub2.stoll.nu
ServerAlias www.sub2.stoll.nu
ServerAdmin webmaster@stoll.nu
DocumentRoot C:/Program/xampp/htdocs/sub2stollnu/
<Directory "C:/Program/xampp/htdocs/sub2stollnu">
AllowOverride All
Options IncludesNoExec
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
från min errorlog:
[Wed Jun 14 16:17:59 2006] [notice] Child 1760: Child process is running
[Wed Jun 14 16:17:59 2006] [notice] Child 1760: Acquired the start mutex.
[Wed Jun 14 16:17:59 2006] [notice] Child 1760: Starting 250 worker threads.
[Wed Jun 14 16:17:59 2006] [notice] Child 1760: Starting thread to listen on port 443.
[Wed Jun 14 16:17:59 2006] [notice] Child 1760: Starting thread to listen on port 80.
[Wed Jun 14 16:17:59 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET /lankar/ HTTP/1.1 to file, referer: http://www.stoll.nu/
[Wed Jun 14 16:18:01 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET /lankar/ HTTP/1.1 to file, referer: http://www.stoll.nu/
[Wed Jun 14 16:20:21 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET /lankar/ HTTP/1.1 to file, referer: http://www.stoll.nu/
[Wed Jun 14 16:20:24 2006] [error] [client 83.227.184.134] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file
[Wed Jun 14 16:21:23 2006] [error] [client 81.225.144.241] (20023)The given path was above the root path: Cannot map GET / HTTP/1.1 to file, referer: http://www.webforum.nu/showthread.php?t=144222
[Wed Jun 14 16:21:23 2006] [error] [client 81.225.144.241] (20023)The given path was above the root path: Cannot map GET /favicon.ico HTTP/1.1 to file
Tyvärr, det var inte hela, den includerar ett antal filer, bl.a. dina vhost direktiv som också skulle vara bra att se.
Det enda jag skulle kunna tänka mig är att du flyttar ut sub1.stoll.nu och sub2.stoll.nu utanför ditt htdocs katalog, ex. C:/Program/xampp/sub1stoll resp. C:/Program/xampp/sub2stoll