Red Hat Bugzilla – Bug 1495500
Global collectd configurations that are set in collectd.d/ will not apply to plugins that are loaded in collectd.conf
Last modified: 2018-06-04 23:46:38 EDT
Description of problem: Global collectd configurations that are set in collectd.d/ will not apply to plugins that are loaded in collectd.conf. For example, if we add a file to collectd.d/ that sets collectd Interval to one that is different from the default 10 sec, It will not affect the plugins that are loaded in collectd.conf. All plugins in collectd.conf should be commented out and they should be loaded from a file in collecd.d/ instead. Version-Release number of selected component (if applicable): 5.7.2 How reproducible: 100% Steps to Reproduce: 1. Add like 00-global_collectd.conf and set Interval 60 2. Restart collectd 3. Review result for plugins that are loaded from the collectd.conf like cpu, memory, interface. Actual results: The plugins that are loaded from collectd.conf stay with the same configs as set in the collectd.conf. Expected results: Should be able to update all plugin configurations from collectd.d/ Additional info:
Didi has fixed the issue in centos-opstools. https://review.rdoproject.org/r/#/c/9802/ Packages needs to be built before this bug can be built before this bug can be fixed and tested.
Can we change to modified?
What parameter should be taken instead of conflict? First defined? sub-dir?
Shirly - ping
(In reply to Lukas Svaty from comment #7) > What parameter should be taken instead of conflict? First defined? sub-dir? Not sure what's the question here, but to clarify - nothing in collectd's behavior/functionality was changed. The only change is in the default collectd.conf. It's now doing nothing except for Include collectd.d. In principle, verification of bug 1478695 should be enough also for current bug.
verified in collectd-5.7.2-3.el7.x86_64
Byron, I do not think the new doc text means what I wanted to imply in the previous one. Tried suggesting a different text, but can't get it right and still much shorter than previous. So instead I'll write in much more detail how we solved the problem. See comment 0 for an explanation of the problem itself. Feel free to update the doc text accordingly. With the fixed version (5.7.2-3), the collectd rpm, when installed, provides a file /etc/collectd.conf which is different from previous versions - it does not load any plugins there anymore. Instead, each of the plugins we want to load by default is loaded from its own separate file, and these files are also now included in the rpm (so you get them if you install it): /etc/collectd.d/90-default-plugins-cpu.conf /etc/collectd.d/90-default-plugins-interface.conf /etc/collectd.d/90-default-plugins-load.conf /etc/collectd.d/90-default-plugins-memory.conf /etc/collectd.d/90-default-plugins-syslog.conf So the default behavior, of loading these plugins by default, did not change at all. In addition, now, if a 3rd-party (such as the ovirt-engine-metrics project) wants to affect the configuration of one or more of these plugins, such a 3rd party can add its own file, to be loaded before these ones, with the needed options. This is much simpler than having to edit /etc/collectd.conf and add the needed options _before_ the relevant LoadPlugin commands. This bug, although is in Product RHV, is regarded as a general "collectd" bug. See bug 1478695 for what we actually wanted. Also, if we decide that current bug needs doc text, perhaps bug 1478695 does too.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:1490