December 2018
Beginner
826 pages
22h 54m
English
When we rotated the logs, and HUPed the syslog daemon, we actually ran this script in logrotate:
$ cat /etc/logrotate.d/syslog /var/log/cron/var/log/maillog/var/log/messages/var/log/secure/var/log/spooler{ missingok sharedscripts postrotate /bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true endscript}
Of course, there's no reason an application has to use the syslog(3) call to log messages, and it could just as easily write a stream of text to /tmp, but that's entirely up to the application developer in question.
All you need to know as an admin is that most logs will probably end up in text format in /var/log, and you can generally configure log file locations on a program-by-program basis.
Happy ...