Linux Log Files & Locations Plus Usage

Go down

Linux Log Files & Locations Plus Usage Empty Linux Log Files & Locations Plus Usage

Post by jamied_uk on 1st November 2016, 19:43

cd /var/log

To view a common log file called /var/log/messages use any one of the following command:


less /var/log/messages
more -f /var/log/messages
cat /var/log/messages
tail -f /var/log/messages
grep -i error /var/log/messages

Common Linux log files

names and usage

    /var/log/messages : General message and system related stuff
    /var/log/auth.log : Authenication logs
    /var/log/kern.log : Kernel logs
    /var/log/cron.log : Crond logs (cron job)
    /var/log/maillog : Mail server logs
    /var/log/qmail/ : Qmail log directory (more files inside this directory)
    /var/log/httpd/ : Apache access and error logs directory
    /var/log/lighttpd/ : Lighttpd access and error logs directory
    /var/log/boot.log : System boot log
    /var/log/mysqld.log : MySQL database server log file
    /var/log/secure or /var/log/auth.log : Authentication log
    /var/log/utmp or /var/log/wtmp : Login records file
    /var/log/yum.log : Yum command log file.

A note about rsyslogd

All of the above logs are generated using rsyslogd service. It is a system utility providing support for message logging. Support of both internet and unix domain sockets enables this utility to support both local and remote logging. You can view its config file by tying the following command:

vi /etc/rsyslog.conf
ls /etc/rsyslog.d/


Posts : 2471
Join date : 2010-05-09
Age : 36
Location : UK

Back to top Go down

Back to top

Permissions in this forum:
You cannot reply to topics in this forum