User Tools

Site Tools


apache:troubleshooting:configuration_file_problems

Apache - Troubleshooting - Configuration file problems

For some websites, the Apache configuration file can grow quite complex over time.

When errors arise with the configuration, being able to quickly pinpoint the source of an error can reduce troubleshooting time.

Apache has two methods for troubleshooting configuration problems.

The first method is the httpd -t option, which can be used to check the Apache configuration file for syntax errors:

httpd -t -c httpd.conf

returns:

Syntax error on line 123 of /etc/httpd/httpd.conf: LogLevel requires level keyword: one of emerg/alert/crit/error/warn/notice/info/debug

NOTE: If an error is present, the configuration check option will print the line that contains the error, and a description of available options if it is able to detect a valid configuration directive.

If Apache fails to start and the configuration check option reports a valid configuration file, the Apache debug log level can be used to have Apache log additional data to the error_log.

To enable the debug log level, the LogLevel directive can be set to debug in the Apache configuration file.

apache/troubleshooting/configuration_file_problems.txt · Last modified: 2021/02/02 09:41 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki