Page 1 of 1

Apache error.log

Posted: Thu Jul 26, 2007 1:08 am
by guitarlvr
I had installed php, mysql, and apache separately and then decided to get rid of them all and try a XAMPP install on windows. Before, when my php files ran into an error, the error.log file in apache would show the error. However with my XAMPP install, no errors get sent to error.log. Any ideas?

Posted: Thu Jul 26, 2007 1:09 am
by John Cartwright
Firstly, please verify your in your ErrorLog in your httpd.conf is pointing to the same file as you expect. Also, what is your LogLevel set to?

Posted: Thu Jul 26, 2007 1:13 am
by guitarlvr
the errorlog location just had "log\error.log" so i changed it to "C:\xampp\apache\logs\error.log". My loglevel is set to warn.

Posted: Thu Jul 26, 2007 10:51 am
by RobertGonzalez
Where is the error log path set?

Posted: Thu Jul 26, 2007 10:52 am
by RobertGonzalez
Oh yeah, and I moved this thread to Installation and Configuration.

Posted: Thu Jul 26, 2007 11:36 am
by guitarlvr
Sorry about posting in the wrong forum.

The log file is located at c:\xampp\apache\logs\error.log.

I currently cannot start apache. i changed the logging values in httpd.conf and php.ini and when i couldnt start i set everything back. i still can't start it. i get a message in my event viewer that says it couldnt start apache because it cannot open error.log. i gave everyone permission to the logs and still no go. :-/

Posted: Thu Jul 26, 2007 11:37 am
by RobertGonzalez
What does the error log path entry in httpd.conf say?

Posted: Thu Jul 26, 2007 11:48 am
by guitarlvr
C:\xampp\apache\logs\error.log

Posted: Thu Jul 26, 2007 12:06 pm
by RobertGonzalez
Change that to either:

Code: Select all

"C:\\xampp\\apache\\logs\\error.log"
or

Code: Select all

"C:/xampp/apache/logs/error.log"
and see if that helps. It might not, but then again, it might.

Posted: Thu Jul 26, 2007 3:17 pm
by guitarlvr
Everah wrote:Change that to either:

Code: Select all

"C:\\xampp\\apache\\logs\\error.log"
or

Code: Select all

"C:/xampp/apache/logs/error.log"
and see if that helps. It might not, but then again, it might.
the first one there was what was causing apache not to start. the second is what i needed to change the path to. why they want "/" and not "" will never make sense to me as a backslash is usually used for a path but thats beyond me. I also was able to get php to log its errors with a couple changes to the php.ini file. Thanks a bunch Everah.

Posted: Thu Jul 26, 2007 3:30 pm
by RobertGonzalez
Backslash '\' is an escape character in many respects. In Apache, it it used in various regular expression pattern handlings, so it needs to be escaped itself. On Windows, Apache sees the forward slash '/' as a completely acceptable path separator and will use that the same way that '\\' is used, typically.

But the cool thing is you got it fixed. Good job.

Posted: Thu Jul 26, 2007 3:55 pm
by guitarlvr
Everah wrote:Backslash '\' is an escape character in many respects. In Apache, it it used in various regular expression pattern handlings, so it needs to be escaped itself. On Windows, Apache sees the forward slash '/' as a completely acceptable path separator and will use that the same way that '\\' is used, typically.
I did not know that. Learn something new everyday :)