logging – Where is “/var/log/messages” on mac-osx? – Server Fault
Posted by jpluimers on 2019/07/29
logging – Where is “/var/log/messages” on mac-osx? – Server Fault
TL;DR: because most of it is in /var/log/system.log
which is configured in /etc/asl.conf
, but the documentation example about syslog.conf
never got updated.
Long read
The example in syslog.conf
is wrong at WayBack: Mac OS X Manual Page For syslog.conf(5) and man syslog.conf
:
EXAMPLES A configuration file might appear as follows: ... # Log anything (except mail) of level info or higher. # Don't log private authentication messages! *.info;mail.none;authpriv.none /var/log/messages ... FILES /etc/syslog.conf The syslogd(8) configuration file.
It still is when writing this [WayBack]syslog.conf(5) Mac OS X Manual Page, so you have to look at /etc/syslog.conf
on a live system:
# Note that flat file logs are now configured in /etc/asl.conf install.* @127.0.0.1:32376
which means the actual configuration is in /etc/asl.conf
:
# Rules for /var/log/system.log > system.log mode=0640 format=bsd rotate=seq compress file_max=5M all_max=50M ? [= Sender kernel] file system.log ? [<= Level notice] file system.log ? [= Facility auth] [<= Level info] file system.log ? [= Facility authpriv] [<= Level info] file system.log
Documentation at [WayBack] asl.conf(5) Mac OS X Manual Page indicates this:
NAME asl.conf -- configuration file for syslogd(8) and aslmanager(8) DESCRIPTION The syslogd(8) server reads the /etc/asl.conf file at startup, and re-reads the file when it receives a HUP signal. The aslmanager(8) daemon reads the file when it starts. See the ASLMANAGER PARAMETER SETTINGS section for details on aslmanager-specific parameters.
Source
Based on [WayBack] logging – Where is “/var/log/messages” on mac-osx? – Server Fault:
Q:
When you read the man pages on Mac OS X, there are references to
/var/log/messages
, but if you look for the file, it doesn’t exist:
$ ls -l /var/log/messages
ls: /var/log/messages: No such file or directoryA:
2009 era: If you look at the actual
/etc/syslog.conf
instead of the man page, you see*.notice;authpriv,remoteauth,ftp,install.none;kern.debug;mail.crit /var/log/system.log
–jeroen
Leave a Reply