Skip to content

dnsmasq log files are not compressed within virtual router #3756

@jtapsl

Description

@jtapsl
ISSUE TYPE
  • Bug Report
COMPONENT NAME
System VM
CLOUDSTACK VERSION
4.13.0
CONFIGURATION

Advanced networking

OS / ENVIRONMENT

RHEL 7.x

SUMMARY
STEPS TO REPRODUCE

Create a virtual router. Wait for dnsmasq.log to exceed 10M and be rotated two or more times. The rotated log files are not compressed.

Contained within cloud-scripts.tgz on systemvm.iso, the file etc/logrotate.d/dnsmasq specifies the delaycompress option. Presumably this means the intention was for the logs to be compressed, but as noted in the manpage for logrotate, the delaycompress option "only has effect when used in combination with compress".

EXPECTED RESULTS

I expected logs dnsmasq.log.2 and higher to be compressed as per this hypothetical output.

$ ls /var/log/dnsmasq.log*
/var/log/dnsmasq.log
/var/log/dnsmasq.log.1
/var/log/dnsmasq.log.2.gz
/var/log/dnsmasq.log.3.gz
ACTUAL RESULTS

None of the log files are compressed.

$ ls /var/log/dnsmasq.log*
/var/log/dnsmasq.log
/var/log/dnsmasq.log.1
/var/log/dnsmasq.log.2
/var/log/dnsmasq.log.3

To fix, the "compress" option should be added to /etc/logrotate.d/dnsmasq

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions