Difference between revisions of "Bering-uClibc 6.x - User Guide - Basic Configuration - Log Files"

From bering-uClibc
Jump to: navigation, search
(Start documenting log file contents)
m (Location and contents of main log files)
Line 21: Line 21:
 
Log files present by default are:
 
Log files present by default are:
  
* <code class="filename">auth.log</code>: This file keeps login information, e.g. the <code class="filename">login</code> and the ssh server <code class="filename">dropbear</code> writes into this file.
+
* <code class="filename">auth.log</code> - This file keeps login information, e.g. the <code class="filename">login</code> and the ssh server <code class="filename">dropbear</code> writes into this file.
* <code class="filename">cron.log</code>: Keeps information of jobs started from cron.
+
* <code class="filename">cron.log</code> - Keeps information of jobs started from cron.
 +
* <code class="filename">dmesg</code> - It's a copy of the dmesg output from the kernel booting, showing the devices it has found and if it has been able to configure them at all (aside from userland configuration).
  
 
tbc
 
tbc
 +
 
===Configuration of syslog-ng===
 
===Configuration of syslog-ng===
 
tbd
 
tbd

Revision as of 16:07, 4 June 2016

Basic Configuration - Log Files
Prev Bering-uClibc 6.x - User Guide Next

Log Files

This chapter explains the location and contents of log files generated on a LEAF Bering-uClibc router, the configuration in syslog-ng, maintenance with logrotate and how to use spacecheck in lrp.conf.

In a space constraint and long running environment like LEAF Bering-uClibc, it will be useful to understand how log files, which tends to grow unlimited, are created and maintained.

Note: Remote logging is not described in this chapter.

Location and contents of main log files

The log files are usually written into /var/log. Some programs writes their log files in subdirectory of /var/log.

Log files present by default are:

  • auth.log - This file keeps login information, e.g. the login and the ssh server dropbear writes into this file.
  • cron.log - Keeps information of jobs started from cron.
  • dmesg - It's a copy of the dmesg output from the kernel booting, showing the devices it has found and if it has been able to configure them at all (aside from userland configuration).

tbc

Configuration of syslog-ng

tbd

Log file maintenance

The task of log file maintenance is accomplished by /usr/bin/logrotate. logrotate is started daily, weekly and monthly from /etc/cron.daily/multicron-d, /etc/cron.weekly/multicron-w and /etc/cron.monthly/multicron-m.

logrotate keeps the configuration files in /etc/logrotate.d, usually named after the application generating the log file (e.g /etc/logrotate.d/ulogd.

logrotate options

tbd

Using Spacecheck in lrp.conf

tbd


Prev Up Next