[collectd] ping plugin is not works in some cases (Linux)
a_s_y at sama.ru
Fri Oct 18 08:57:31 CEST 2019
On Thursday 17 October 2019, Sergey wrote:
> I attempt to use ping plugin and I found that it is not works
> in incomprehensible cases. I have 3 systems with identical
> configurations. The one works and other two don't.
> collectd 5.9.1, identical rpm package. Configuration is fully same:
> <Plugin ping>
> Host "localhost"
> The only difference is a hostname. The working system has real
> hostname with full DNS support, other two is a notebooks with
> local defined hostnames. I don't see any other difference.
> cpu, load and memory plugins works. Can anyone suggest anything?
For some reason I did not look in the log...
collectd: read-function of plugin `ping' failed. Will suspend it for 20.000 seconds.
collectd: ping plugin: ping_host_add (localhost) failed: Operation not permitted
collectd: ping plugin: No host could be added to ping object. Giving up.
collectd: ping plugin: The ping thread had a problem. Restarting it.
I forgot another difference between working and nonworking systems:
systemd used as init on nonworking systems. And it's the problem like
SELinux. It is even mentioned in collectd.service:
# A few plugins won't work without some privileges, which you'll have to
# specify using the CapabilityBoundingSet directive below.
# Here's a (incomplete) list of the plugins known capability requirements:
# ceph CAP_DAC_OVERRIDE
# dns CAP_NET_RAW
# exec CAP_SETUID CAP_SETGID
# intel_rdt CAP_SYS_RAWIO
# intel_pmu CAP_SYS_ADMIN
# iptables CAP_NET_ADMIN
# ping CAP_NET_RAW
# processes CAP_NET_ADMIN (CollectDelayAccounting only)
# smart CAP_SYS_RAWIO
# turbostat CAP_SYS_RAWIO
# Example, if you use the iptables plugin alongside the dns or ping plugin:
More information about the collectd