Apache2 (Http Server )

Motivation

i was learning about the apache so thought why not document the complete stuff i learned in a single blogpost.

Apache Web Server

Logs

Access Logs

this will show the requests made by the user and it is a general logs it shows who made a request at what time and what resource is being requested

Error Logs

this will show general error message encountered by the server

for me --> apache2/logs/error_log is the file for the error logs

Log Level Directive

these directive will make the logs more verbose or less verbose based on the requirement.

these are the log level

emerg Shows emergencies that may have rendered the server unusable. alert Shows errors that must be solved immediately. crit Shows critical conditions. error Shows error conditions. warn Shows warning conditions, which are generally not errors, but issues that must be solved. notice Shows normal notices, information that can help fix future issues may be because of deprecated syntax, or non-declared variables, etc. info Shows informational messages. debug Shows debug level messages which can be used by developers to debug what is happening in the code. trace1 Trace messages. trace2 Trace messages. trace3 Trace messages. trace4 Trace messages. trace5 Trace messages. trace6 Trace messages. trace7 Trace messages. trace8 Trace messages.

  • Whatever level we selected above that level log is implemented.

LogLevel alert rewrite:warn