• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue Logrotate for nginx proxy_access_ssl_log

bernhardh86

Basic Pleskian
Server operating system version
Ubuntu 20.04
Plesk version and microupdate number
18.0.42
I have done all settings in Plesk to have a daily log rotation (and keep the files 7 days).

1665053258024.png


It works for the access_log and access_ssl_log (and I don't use apache at all, since I have disabled proxy mode), but i is not applied to the nginx proxy_access_ssl_log. There is always just one file of proxy_access_ssl_log.

Digging deeper, I found the file `/opt/psa/etc/logrotate.d/mydomain.at` with the settings in it:

#ATTENTION!
#
#DO NOT MODIFY THIS FILE BECAUSE IT WAS GENERATED AUTOMATICALLY,
#SO ALL YOUR CHANGES WILL BE LOST THE NEXT TIME THE FILE IS GENERATED.
/var/www/vhosts/system/mydomain.at/logs/*.processed {
daily
rotate 7
compress
missingok
copytruncate
}
/var/www/vhosts/system/mydomain.at/logs/error_log {
daily
rotate 7
compress
missingok
copytruncate
}
/var/www/vhosts/system/mydomain.at/logs/proxy_error_log {
daily
rotate 7
compress
missingok
copytruncate
}

Interesting! There is no setting for proxy_access_ssl_log. And I can't add it there, since it would be overwritten.
 
It's expected behavior. The contents of the logfiles proxy_access_log and proxy_access_ssl_log are merged with access_log for further statistics calculations.
In the meantime, the logs themselves start over so that the web server continues to write logs while statistics for the past day are calculated.

Plesk Support will soon release a support page where this behavior is explained.
 
Back
Top