FS#51721 - [nginx] better log rotation

Attached to Project: Arch Linux
Opened by Oscar Garcia (ogarcia) - Sunday, 06 November 2016, 13:56 GMT
Last edited by Bartłomiej Piotrowski (Barthalion) - Friday, 18 November 2016, 20:24 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To Sébastien Luttringer (seblu)
Bartłomiej Piotrowski (Barthalion)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Please add the option `notifempty` to logrotate file.

Now if any of yours log files is empty is rotated anyway, and this produces an unnecessary compressed file as following sample:
-rw-r----- 1 http log 0 Nov 6 00:00 error.log
-rw-r----- 1 http log 20 Oct 30 00:01 error.log.1.gz
-rw-r----- 1 http log 20 Oct 23 00:00 error.log.2.gz
-rw-r----- 1 http log 20 Oct 16 00:00 error.log.3.gz

With notifempty option the file is rotated only if have some data. This is the default behavior in other distributions.
This task depends upon

Closed by  Bartłomiej Piotrowski (Barthalion)
Friday, 18 November 2016, 20:24 GMT
Reason for closing:  Fixed
Additional comments about closing:  nginx 1.10.2-2, nginx-mainline 1.11.6-1

Loading...