golden hour
/etc/logrotate.d
⬆️ Go Up
Upload
File/Folder
Size
Actions
alternatives
120 B
Del
OK
apache2
442 B
Del
OK
apt
173 B
Del
OK
bootlog
91 B
Del
OK
btmp
130 B
Del
OK
certbot
82 B
Del
OK
dpkg
112 B
Del
OK
mysql-server
802 B
Del
OK
rsyslog
501 B
Del
OK
ubuntu-advantage-tools
119 B
Del
OK
ufw
178 B
Del
OK
wtmp
145 B
Del
OK
Edit: mysql-server
# - I put everything in one block and added sharedscripts, so that mysql gets # flush-logs'd only once. # Else the binary logs would automatically increase by n times every day. # - The error log is obsolete, messages go to syslog now. /var/log/mysql/mysql.log /var/log/mysql/mysql-slow.log /var/log/mysql/mariadb-slow.log /var/log/mysql/error.log { daily rotate 7 missingok create 640 mysql adm compress sharedscripts postrotate test -x /usr/bin/mysqladmin || exit 0 if [ -f `my_print_defaults --mysqld | grep -m 1 -oP "pid-file=\K.+$"` ]; then # If this fails, check debian.conf! mysqladmin --defaults-file=/etc/mysql/debian.cnf --local flush-error-log \ flush-engine-log flush-general-log flush-slow-log fi endscript }
Save