1

I have an Apache bug.

(https://bugs.launchpad.net/ubuntu/+source/apache2/+bug/1945311 - Ubuntu 18 version 2.4.29-1ubuntu4.18 on my Plesk Ubuntu server).

I found a workaround here:

https://support.plesk.com/hc/en-us/articles/4407366133906-Website-suddenly-started-to-show-500-error-AH10292-Invalid-proxy-UDS-filename?page=2#comments

And execute (before it was officially fixed by Apache):

sudo add-apt-repository ppa:ondrej/apache2
sudo apt install apache2

After that I get daily new messages with:

/etc/cron.daily/logrotate:
error: apache2.distrib:1 duplicate log entry for /var/log/apache2/access.log

Do you have tips for me?

Was the workaround a safe method to add a new repository I don't know the creator?

David
  • 2,101
  • 13
  • 16
  • 25
Mike
  • 411

1 Answers1

1

There are two files in /etc/logrotate.d: /etc/logrotate.d/apache2 and /etc/logrotate.d/apache2.distrib. The latter is the renamed and diverted logrotate file originally distributed by the apache2 package, while the former is the one shipped/created by Plesk (it seems). The diversion, created with dpkg-divert, seems to have been created by Plesk too.

Both files contain rules for the same set of log files, which leads to the logrotate warning message, which is then announced by cron via mail.

The solution is very simple: comment out the whole entry in /etc/logrotate.d/apache2.distrib.

So this is not a bug in the apache2 package. Instead, the Plesk packages could improve handling this diversion to not leave two files in /etc/logrotate.d referencing the same log files.