Multiple sites on Xampp

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Multiple sites on Xampp

Postby moonshinerat » 07. May 2008 04:31

Evening guys.

I'm getting kinda frustrated with Xampp now, trying to setup multiple sites.

For six weeks, I have tried each day a different method shown on the official documentation, three different forums and a number of independent websites to get Xampp to see multiple websites. I don't know what I am doing wrong, but I have tried this on Linux and Windows and keep getting the same result - server not found.

Please don't be offended by my frustration but I've been a network engineer for thirteen years. I have tried the solutions in fifteen threads and nine independentant sites. None of them work.

My current vhosts file looks like this:

NameVirtualHost *:80

<VirtualHost *:80>
ServerAdmin webmaster@localhost.bgtrks.dev
DocumentRoot "Z:/Websites/Development/bigtracks"
ServerName localhost.bigtracks.dev
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@localhost.galoeng.dev
DocumentRoot "Z:/Websites/Development/galoeng"
ServerName localhost.galoeng.dev
</VirtualHost>

<VirtualHost *:80>
ServerAdmin webmaster@localhost.goldmonkey.dev
DocumentRoot "Z:/Websites/Development/goldmonkey"
ServerName localhost.goldmonkey.dev
</VirtualHost>

I obviously have a drive Z with Websites/Development/websitename on.

My hosts file looks like this:

127.0.0.1 localhost
127.0.0.1 localhost.bgtrks.dev
127.0.0.1 localhost.galoeng.dev
127.0.0.1 localhost.goldmonkey.dev

I have tried:

http://www.localhost.bgtrks.dev
http://localhost.bgtrks.dev

and so on with the other site names.

http://localhost

gives me a permission denied or directory does not exist error. The other site names give me a server not found error.

I really need this to be up an running. When I had two PC's this was not a problem in Apache but trying to run sites on virtual hosts is becoming a bit of a joke.

Any help appreciated folks.
moonshinerat
 
Posts: 4
Joined: 21. April 2008 17:14

Postby Nobbie » 07. May 2008 11:30

1) There is missing a vhost for localhost

2) In all vhosts is missing a <directory xxxx> configuration (where xxxx stands for the value of DocumentRoot), where the Apache Rights are granted (Options, Order deny, allow etc.). One example:

Code: Select all
<Directory Z:/Websites/Development/bigtracks>
    Options Indexes FollowSymLinks Includes ExecCGI
    AllowOverride All
    Order allow,deny
    Allow from all
</Directory>


You have to insert this block in for each virtual host.

3) If Z: is mapped to a different server or pc, you must establish the connection before Apache starts. Also Apache must run with sufficient rights to access to net drive. Therefore, usually you CANNOT start apache as a service, but you have to start it from the Xampp panel after the PC has bootet and after all connections have established.
Nobbie
 
Posts: 8779
Joined: 09. March 2008 13:04


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 50 guests