Updated: 28 September 2026 · Applies to: AlmaLinux 9, Rocky Linux 9, Ubuntu 24.04 and Debian 12
Logrotate reports "duplicate log entry for /var/lib/mysql/mysqld.log" when two configuration files rotate the same log, usually /etc/logrotate.d/mysql and /etc/logrotate.d/mysqld.
Fix (root)
- List them:
ls -l /etc/logrotate.d/mysql* - Keep one. Move the other out of the folder, for example
mv /etc/logrotate.d/mysql /root/logrotate-mysql.bak. - Test:
logrotate -d /etc/logrotate.conf.