Hi everyone.
I just wondered what's the difference between /var/log/dmesg, and /var/log/messages?
Why do we have 2 log files that are similar?
Kind Regards,
Keith Roberts
----------------------------------------------------------------- Websites: http://www.karsites.net http://www.php-debuggers.net http://www.raised-from-the-dead.org.uk
All email addresses are challenge-response protected with TMDA [http://tmda.net] -----------------------------------------------------------------
dmesg is everything sent from the kernel for logging (ie. the historical content of the dmesg(8) command).
messages is basically a syslog fall-through (a bit like /var/log/syslog)
On 21/01/2011, at 7:02 AM, Keith Roberts wrote:
Hi everyone.
I just wondered what's the difference between /var/log/dmesg, and /var/log/messages?
Why do we have 2 log files that are similar?
Kind Regards,
Keith Roberts
Websites: http://www.karsites.net http://www.php-debuggers.net http://www.raised-from-the-dead.org.uk
All email addresses are challenge-response protected with TMDA [http://tmda.net]
CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos
On Fri, 21 Jan 2011, Cameron Kerr wrote:
dmesg is everything sent from the kernel for logging (ie. the historical content of the dmesg(8) command).
messages is basically a syslog fall-through (a bit like /var/log/syslog)
See /etc/rc.sysinit for dmesg invocation that writes to /var/log/dmesg; the LOGLEVEL shell variable is set in /etc/sysconfig/init.
The content of /var/log/messages is controlled via /etc/syslog.conf.
On Thu, 20 Jan 2011, Paul Heinlein wrote:
To: CentOS mailing list centos@centos.org From: Paul Heinlein heinlein@madboa.com Subject: Re: [CentOS] dmesg and messages differences
On Fri, 21 Jan 2011, Cameron Kerr wrote:
dmesg is everything sent from the kernel for logging (ie. the historical content of the dmesg(8) command).
messages is basically a syslog fall-through (a bit like /var/log/syslog)
See /etc/rc.sysinit for dmesg invocation that writes to /var/log/dmesg; the LOGLEVEL shell variable is set in /etc/sysconfig/init.
The content of /var/log/messages is controlled via /etc/syslog.conf.
Thanks guys for that concise answer.
I guess I need to read up on the man page for syslogd :)
Keith
----------------------------------------------------------------- Websites: http://www.karsites.net http://www.php-debuggers.net http://www.raised-from-the-dead.org.uk
All email addresses are challenge-response protected with TMDA [http://tmda.net] -----------------------------------------------------------------
On Thu, Jan 20, 2011 at 06:28:35PM +0000, Keith Roberts wrote:
On Thu, 20 Jan 2011, Paul Heinlein wrote:
To: CentOS mailing list centos@centos.org From: Paul Heinlein heinlein@madboa.com Subject: Re: [CentOS] dmesg and messages differences
On Fri, 21 Jan 2011, Cameron Kerr wrote:
dmesg is everything sent from the kernel for logging (ie. the historical content of the dmesg(8) command).
...specifically, the content just after booting is more or less complete; it's not subsequently updated (as someone else already wrote in).
The content of /var/log/messages is controlled via /etc/syslog.conf.
Thanks guys for that concise answer.
I guess I need to read up on the man page for syslogd :)
Specifically, man syslog.conf for that file's syntax; man syslogd talks more about its invocation and signalling.
--keith
Keith Keller wrote: <snip>
Specifically, man syslog.conf for that file's syntax; man syslogd talks more about its invocation and signalling.
And the difference can be *very* important. For example, last night, one of our servers had a h/d crap out, and dropped to ro. However, all of them copy the log entries to a log server, so from *there* we could see the drive errors happening.
mark
On 01/20/11 10:02 AM, Keith Roberts wrote:
Hi everyone.
I just wondered what's the difference between /var/log/dmesg, and /var/log/messages?
/var/log/dmesg is a dump of the output of the dmesg command shortly after boot by rc.sysinit. this is done because the kernel message buffer that dmesg (8) dumps often overflows and wraps during normal operations with crud like...
TCP: Treason uncloaked! Peer 87.181.155.69:49289/8068 shrinks window 3515263916:3515269047. Repaired.
/var/log/messages is the catch-all for syslogd (8), and is updated constantly.