Computer data logging

From Wikipedia, the free encyclopedia

In computerized data logging, a computer program automatically records events in a certain scope in order to provide an audit trail that can be used to understand the activity of the system and to diagnose problems.

[edit] Examples

Examples of physical systems which have logging subsystems include process control systems, and the black box recorders installed in aircraft.

Many operating systems and multitudinous computer programs include some form of logging subsystem.

In the simplest case, log messages are written to a log file. Most operating systems and software frameworks also provide more sophisticated services for logging. One example is the syslog service (described in RFC 3164), which allows the filtering and recording of log messages to be performed by a separate dedicated subsystem, rather than placing the onus on each application to provide its own ad hoc logging system.

[edit] Uses of logs

Logs are essential to understanding the activities of complex systems, and to analyze problems, particularly in the case of applications with little user interaction (such as server applications).

However, in many cases, the logs are esoteric or too verbose and therefore hard to understand; they need to be subjected to log analysis in order to make sense of them. This is often done using special log analysis software.

It can be useful to combine log file entries from multiple sources. This approach, in combination with statistical analysis, may yield correlations between seemingly-unrelated events on different servers. Other solutions employ network-wide querying and reporting.

[edit] Transaction log

Main article: Transaction log

Most Databases maintain some kind of transaction log. Unlike the logs described above, these logs are not mainly intended as an audit trail for later analysis, and are not (easily) human-readable. Instead, they record changes to the stored data to allow the database to recover from crashes or other errors and maintain the stored data in a consistent state.

Most database systems have both a log in the general sense described above, and a transaction log.