-
Problem report
-
Resolution: Fixed
-
Trivial
-
4.0.11, 4.2.5
-
Sprint 56 (Sep 2019), Sprint 55 (Aug 2019), Sprint 57 (Oct 2019)
-
1
After log rotating with compression by outer program, e.g. linux logrotate, stdout and stderr redirections which are duplicated on daemon starting, are vanished. It affects that libraries, e.g. libcurl and net-snmp, can not output to log file.
It has already been report in ZBX-6028 and by lsof command you can confirm.
$ sudo lsof | grep /var/log/zabbix/zabbix_server.log zabbix_se 23684 zabbix 1w REG 253,0 87348 673754 /var/log/zabbix/zabbix_server.log.1 (deleted) zabbix_se 23684 zabbix 2w REG 253,0 87348 673754 /var/log/zabbix/zabbix_server.log.1 (deleted) zabbix_se 23694 zabbix 1w REG 253,0 87348 673754 /var/log/zabbix/zabbix_server.log.1 (deleted) zabbix_se 23694 zabbix 2w REG 253,0 87348 673754 /var/log/zabbix/zabbix_server.log.1 (deleted) zabbix_se 23695 zabbix 1w REG 253,0 87348 673754 /var/log/zabbix/zabbix_server.log.1 (deleted) zabbix_se 23695 zabbix 2w REG 253,0 87348 673754 /var/log/zabbix/zabbix_server.log.1 (deleted)
...
For this problem, many application, e.g. Apache httpd, support HUP signal to change redirection and suggest to send HUP signal after log rotation. So, I attached the patch.