Apache Log Files

RSS
EMAIL
FACEBOOK
FACEBOOK
GOOGLE
GOOGLE
https://www.poftut.com/apache-log-files/
PINTEREST
PINTEREST
INSTAGRAM

Apache or with real name httpd provides logs. These logs are very helpful while detecting errors, attacks. There is two type of Apache logs by default. Log resides in following directories.

/var/log/httpd/

  • CentOS
  • Redhat
  • Fedora

/var/log/apache2/

  • Ubuntu
  • Debian
  • Kali

Getting Log Files Directory

Log file directory can be changed with Apache configuration. Look in to configuration file to exact log path

Ubuntu,Debian,Kali

CentOS,Fedora, Red Hat

Error Logs

Error logs are generally related with service and http request errors. For different distributions different paths exists but generally similar paths are used.

We can read error logs like below. We use less to read.

We can also search error file with grep

LEARN MORE  Linux Find Command With Examples

Access Logs

Access logs generally provides http request related information and for busy site it will be generated a lot.

We can search like error log with grep. We will search for 404 messages

LEARN MORE  How To Find External or Wan Ip Address Without Browser

RSS
EMAIL
FACEBOOK
FACEBOOK
GOOGLE
GOOGLE
https://www.poftut.com/apache-log-files/
PINTEREST
PINTEREST
INSTAGRAM

Leave a Reply

Your email address will not be published.