Home » Questions » Computers [ Ask a new question ]

Apache2 error log

Apache2 error log

I can't seem to find the error log for apache on my locahost on Ubuntu. I have apache2 installed.

Asked by: Guest | Views: 207
Total answers/comments: 1
Guest [Entry]

"Check your httpd.conf to see if you have the following line or something very similiar:

ErrorLog ""logs/error.log""

It might be in a different directory, or it might be called something else, but if you don't have a line in the Apache configuration file starting with ErrorLog, you're probably not catching the errors.

If that's good, double-check to make sure you haven't got the LogLevel commented out:

# LogLevel: Control the number of messages logged to the error_log.
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
#
LogLevel warn

The default setting is warn, which is about on the edge of way too much info and waiting for a more serious fault in the localhost. If it's commented out, with a hash (#) starting the line, you also won't be catching any errors in the log file despite the ErrorLog setting.

You can compare what each level setting of LogLevel is in the Apache server documentation."