…Apache error logs are configured with a couple of directives.…The first, ErrorLog, defines the name and location.…The file created is typically called error log or error.log.…The next directive is LogLevel, which controls the verbosity, or…detail, of the error logs.…LogLevels are defined in the Apache documentation.…At high level the default is warn but info can be a bit more verbose.…
The least verbose level is emergency which only logs when the system is unusable and…on the other end of the spectrum you can go to stack traces which dump…vast amounts of data useful only if you're actually developing Apache functionality.…Most Apache servers are configured to log errors already.…The trick is figuring out where it's logging to.…Switch to the terminal.…Let's use grep to recursively and…case insensitively search the configuration files for error log.…So we're going to look for ErrorLog in etc apache2.…The main ErrorLog is defined as APACHE_LOG_DIR/error.log.…This is an environmental variable,…meaning APACHE_LOG_DIR is defined in another place.…
Share this video
Embed this video
Video: Enabling and reading Apache log files