Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # daemon does not need restarting after log rotate
- # so we do not prod it any more
- /var/log/exim/*log {
- compress
- daily
- missingok
- notifempty
- delaycompress
- }
- #
- # Gentoo:
- # http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/net-analyzer/fail2ban/files/fail2ban-logrotate?view=markup
- #
- # Debian:
- # https://github.com/fail2ban/fail2ban/blob/debian/debian/fail2ban.logrotate
- /var/log/fail2ban.log {
- missingok
- notifempty
- postrotate
- /usr/bin/fail2ban-client flushlogs >/dev/null || true
- endscript
- }
- /var/log/httpd/*log {
- missingok
- notifempty
- sharedscripts
- delaycompress
- postrotate
- /bin/systemctl reload httpd.service > /dev/null 2>/dev/null || true
- endscript
- }
- # This logname can be set in /etc/my.cnf
- # by setting the variable "log-error"
- # in the [mysqld_safe] section as follows:
- #
- # [mysqld_safe]
- # log-error=/var/log/mariadb/mariadb.log
- #
- # If the root user has a password you have to create a
- # /root/.my.cnf configuration file with the following
- # content:
- #
- # [mysqladmin]
- # password = <secret>
- # user= root
- #
- # where "<secret>" is the password.
- #
- # ATTENTION: This /root/.my.cnf should be readable ONLY
- # for root !
- # Then, un-comment the following lines to enable rotation of mysql's log file:
- /var/log/mariadb/mariadb.log {
- create 640 mysql mysql
- notifempty
- daily
- rotate 3
- missingok
- compress
- postrotate
- # just if mysqld is really running
- if test -x /usr/bin/mysqladmin && \
- /usr/bin/mysqladmin ping &>/dev/null
- then
- /usr/bin/mysqladmin flush-logs
- fi
- endscript
- }
- /var/named/data/named.run {
- missingok
- su named named
- create 0644 named named
- postrotate
- /usr/bin/systemctl reload named.service > /dev/null 2>&1 || true
- /usr/bin/systemctl reload named-chroot.service > /dev/null 2>&1 || true
- /usr/bin/systemctl reload named-sdb.service > /dev/null 2>&1 || true
- /usr/bin/systemctl reload named-sdb-chroot.service > /dev/null 2>&1 || true
- /usr/bin/systemctl reload named-pkcs11.service > /dev/null 2>&1 || true
- endscript
- }
- # Logrotate file for ppp RPM
- /var/log/ppp/connect-errors {
- missingok
- compress
- notifempty
- daily
- rotate 5
- create 0600 root root
- }
- /var/log/proftpd/*.log /var/log/xferlog {
- compress
- missingok
- notifempty
- sharedscripts
- postrotate
- systemctl reload proftpd.service
- endscript
- }
- /var/log/roundcubemail/*.log {
- missingok
- su root apache
- notifempty
- size 30k
- nocreate
- }
- /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
- }
- /var/log/wpa_supplicant.log {
- missingok
- notifempty
- size 30k
- create 0600 root root
- }
- /var/log/yum.log {
- missingok
- notifempty
- size 30k
- yearly
- create 0600 root root
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement