Skip to Main Content
Learning Debian GNU/Linux
book

Learning Debian GNU/Linux

by Bill McCarty
October 1999
Beginner to intermediate content levelBeginner to intermediate
360 pages
10h 18m
English
O'Reilly Media, Inc.
Content preview from Learning Debian GNU/Linux

Viewing System Messages and Logs

Linux maintains several system logs that help you administer a Linux system by informing you of important events. Probably the most important log is the file /var/log/messages, which records a variety of events, including system error messages, system startups, and system shutdowns. Like most other Linux files, the file contains ASCII text, so you can view it with a text editor or the text processing commands described in Chapter 13.

A special command, dmesg, makes it easy to view the log messages related to the most recent system startup. If your system is behaving unusually, use dmesg to quickly see if something went wrong during the system startup sequence. Of course, you must have some way of determining what’s usual and unusual among the many messages emitted during system startup. The best way to do so is to print the output of the dmesg command and keep it on hand for comparison with suspicious output. If your system has an attached printer, you can print the output of dmesg by entering the following command:

dmesg | lpr

Other logs found in the /var/log directory include:

apache

directory that contains two log files pertaining to the Apache web server, access.log and error.log.

exim

A directory that contains several log files pertaining to the exim mail transfer agent.

nmb and smb

Files that contain log entries pertaining to Samba, the Microsoft-compatible networking server.

ppp.log

A file the contains log entries pertaining to PPP. ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Linux in Action

Linux in Action

David Clinton

Publisher Resources

ISBN: 1565927052Supplemental ContentCatalog PageErrata