Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#531352: Collectd - problems with netlink on x86_64

48 views
Skip to first unread message

Marcos Taschelmayer

unread,
May 31, 2009, 5:20:15 PM5/31/09
to
Package: collectd
Version: 4.4.2-3
Architecture: amd64

I'm using the plugin netlink like follow:

(...)
LoadPlugin netlink
(...)
<Plugin netlink>
Interface "All"
VerboseInterface "All"
QDisc "ifb0" "prio-1:0"
(...)
#Class "ppp0" "htb-1:10"
#Filter "ppp0" "u32-1:0"
#IgnoreSelected false
</Plugin>

If I restart the collectd daemon we found a problem:

# /etc/init.d/collectd restart
Restarting statistics collection and monitoring daemon: collectdCould
not find plugin netlink.
.

This configuration works fine on i386. The problem is on amd64,
because the collectd didn't found the netlink plugin. See the follow
logs:

May 31 17:33:37 autofw collectd[6754]: Found a configuration for the
`netlink' plugin, but the plugin isn't loaded or didn't register a
configuration callback.
May 31 17:33:37 autofw collectd[6754]: Found a configuration for the
`netlink' plugin, but the plugin isn't loaded or didn't register a
configuration callback.

On i386 the plugin is available:
# dpkg -L collectd | grep netlink
/usr/lib/collectd/netlink.so

But on amd64 not:
# dpkg -L collectd | grep netlink

I'm using Debian GNU/Linux 5.0.1, kernel 2.6.26-2-amd64 and libc6
2.7-18.


Thanks in advance,


Marcos Taschelmayer

--
To UNSUBSCRIBE, email to debian-bugs-...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org

Sebastian Harl

unread,
Jun 1, 2009, 3:20:06 AM6/1/09
to
retitle 531352 collectd: netlink plugin missing on amd64 (et.al.)
thanks

Hi Marcos,

On Sun, May 31, 2009 at 06:08:15PM -0300, Marcos Taschelmayer wrote:
> Architecture: amd64
[...]


> # /etc/init.d/collectd restart
> Restarting statistics collection and monitoring daemon: collectdCould
> not find plugin netlink.

Yep - that's a known problem. The netlink plugin requires libnetlink
which is only available as a static library compiled without -fPIC
(position independent code). Some (most?) architectures, like amd64, do
not allow to link such object files into shared libraries. See [1] for
some more details about this problem.

So, unfortunately, I'm currently unable to provide the netlink plugin on
those architectures. There are two ways how to resolve that issue:
Either, include libnetlink in collectd and build it with -fPIC or let
the iproute package provide a shared library as well. Including the
sources in collectd would not be hard but I don't really like that
option since that would duplicate code and efforts. I've talked to the
iproute maintainer before and he told me that a shared library would not
be an option. It might be worth talking to the iproute upstream
developers about that though - maybe they are willing to support a
shared object some time in the future which could then be included in
the Debian package as well. Do you want to give that a try?

Cheers,
Sebastian

[1] http://collectd.org/faq.shtml#faq:static_libs

--
Sebastian "tokkee" Harl +++ GnuPG-ID: 0x8501C7FC +++ http://tokkee.org/

Those who would give up Essential Liberty to purchase a little Temporary
Safety, deserve neither Liberty nor Safety. -- Benjamin Franklin

signature.asc
0 new messages