Error logged when Apache starts

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

Error logged when Apache starts

Postby ajax » 01. December 2018 22:17

I'm trying to bring up a new installation of XAMPP on Windows. Using the portable version. Trying to convert a server running on an older version of XAMPP to this instance. When I start Apache the error log contains the following:

AH00112: Warning: DocumentRoot [D:/xampp/apache/mydomain.com] does not exist

However, HTTPD.CONF contains the following:

DocumentRoot "/xampp/htdocs"
<Directory "/xampp/htdocs">

I do notice that the conf files are stored under "/xampp/apache" but I cannot find any reference to xampp/apache anywhere in the Apache conf file named "HTTPD.CONF" or in "D:\xampp\apache\conf\extra\httpd-vhosts.conf" which is the only configuration file I've updated.

Can anyone explain what's going on?
ajax
 
Posts: 35
Joined: 14. December 2010 17:57
Operating System: Windows 2000 Professional

Re: Error logged when Apache starts

Postby Nobbie » 01. December 2018 22:55

I think you overlooked anything, run a global find over the Xampp installation. Apache definately does not "invent" DocumentRoots.
Nobbie
 
Posts: 13183
Joined: 09. March 2008 13:04

Re: Error logged when Apache starts

Postby ajax » 02. December 2018 17:20

For troubleshooting I returned to the original (out of the box so to speak) xampp configuration and verified that apache would start without the subject error. The only change that I then made to the original xampp configuration is to add my virtual host to "D:\xampp\apache\conf\extra\httpd-vhosts.conf" as shown below, which produces the error when starting apache.

I can find only one place in the apache configuration (HTTPD.CONF) which contains the string "xampp/apache" and it follows:

#
Define SRVROOT "/xampp/apache"
ServerRoot "/xampp/apache"
#

Is it possible that there is some circumstance under which ServerRoot is used for DocumentRoot? That appears to be what is happening.

***Following is my revised version of "D:\xampp\apache\conf\extra\httpd-vhosts.conf" ***

# Virtual Hosts
#
# Required modules: mod_log_config

# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
#
# Please see the documentation at
# <URL:http://httpd.apache.org/docs/2.4/vhosts/>
# for further details before you try to setup virtual hosts.
#
# You may use the command line option '-S' to verify your virtual host
# configuration.

#
# Use name-based virtual hosting.
#
##NameVirtualHost *:80
#
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for all requests that do not
# match a ##ServerName or ##ServerAlias in any <VirtualHost> block.
#
##<VirtualHost *:80>
##ServerAdmin webmaster@dummy-host.example.com
##DocumentRoot "/xampp/htdocs/dummy-host.example.com"
##ServerName dummy-host.example.com
##ServerAlias www.dummy-host.example.com
##ErrorLog "logs/dummy-host.example.com-error.log"
##CustomLog "logs/dummy-host.example.com-access.log" common
##</VirtualHost>

##<VirtualHost *:80>
##ServerAdmin webmaster@dummy-host2.example.com
##DocumentRoot "/xampp/htdocs/dummy-host2.example.com"
##ServerName dummy-host2.example.com
##ErrorLog "logs/dummy-host2.example.com-error.log"
##CustomLog "logs/dummy-host2.example.com-access.log" common
##</VirtualHost>

#DG-> Virtual host for project=mydomain.com
<VirtualHost *:80>
DocumentRoot "mydomain.com"
ServerName mydomain.com
ErrorLog "logs/error.log"
CustomLog "logs/access.log" combined
#
# This should be changed to whatever you set DocumentRoot to.
#
<Directory "mydomain.com">
#ErrorDocument 404 /PageNotFound.php
#
# Possible values for the Options directive are "None", "All",
# or any combination of:
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important. Please see
# http://httpd.apache.org/docs/2.2/mod/core.html#options
# for more information.
#
Options Indexes FollowSymLinks Includes ExecCGI

#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
# Options FileInfo AuthConfig Limit
#
AllowOverride All

#
# Controls who can get stuff from this server.
#
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
ajax
 
Posts: 35
Joined: 14. December 2010 17:57
Operating System: Windows 2000 Professional

Re: Error logged when Apache starts

Postby ajax » 02. December 2018 19:49

Finally figured out how to search all of the *.CONF files in directory /xampp/apache for the string "xampp/apache" and what I found is shown below. I see no clues about how DocumentRoot gets set '/xampp/apache". Surely, using <VirtualHost> is a common need when using xampp.

Results for search of *.conf files for the string "xampp/apache" follow:
D:\xampp\apache\conf\extra\httpd-autoindex.conf (2 hits)
Line 23: Alias /icons/ "/xampp/apache/icons/"
Line 25: <Directory "/xampp/apache/icons">
D:\xampp\apache\conf\extra\httpd-dav.conf (1 hit)
Line 20: DavLockDB "/xampp/apache/logs/Dav.Lock"
D:\xampp\apache\conf\extra\httpd-manual.conf (2 hits)
Line 11: AliasMatch ^/manual(?:/(?:da|de|en|es|fr|ja|ko|pt-br|ru|tr|zh-cn))?(/.*)?$ "/xampp/apache/manual$1"
Line 13: <Directory "/xampp/apache/manual">
D:\xampp\apache\conf\extra\httpd-multilang-errordoc.conf (2 hits)
Line 26: Alias /error/ "/xampp/apache/error/"
Line 28: <Directory "/xampp/apache/error">
D:\xampp\apache\conf\extra\httpd-ssl.conf (6 hits)
Line 91: #SSLSessionCache "shmcb:/xampp/apache/logs/ssl_scache(512000)"
Line 92: SSLSessionCache "shmcb:/xampp/apache/logs/ssl_scache(512000)"
Line 127: ErrorLog "/xampp/apache/logs/error.log"
Line 128: TransferLog "/xampp/apache/logs/access.log"
Line 251: <Directory "/xampp/apache/cgi-bin">
Line 286: CustomLog "/xampp/apache/logs/ssl_request.log" \
D:\xampp\apache\conf\extra\httpd-xampp.conf (1 hit)
Line 8: SetEnv OPENSSL_CONF "/xampp/apache/bin/openssl.cnf"
D:\xampp\apache\conf\httpd.conf (2 hits)
Line 37: Define SRVROOT "/xampp/apache"
Line 39: ServerRoot "/xampp/apache"
ajax
 
Posts: 35
Joined: 14. December 2010 17:57
Operating System: Windows 2000 Professional


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 110 guests