[collectd] Modbus segfault
Matt Baker
matt at sevenone.com
Thu Dec 15 16:02:39 CET 2011
Hi,
I am trying to get collectd working with the modbus plugin but I am getting a segfault each time collectd runs:
Dec 16 01:20:55 vmunix: [1074386.330565] collectd[29149]: segfault at 20 ip b7e03bcc sp b6fa1270 error 4 in libmodbus.so.4.0.0[b7e02000+6000]
Using Collectd version 5.0.1 with libmodbus 2.9.2 (have also tried 2.9.4 & 3.0.1). Running ldd on the modbus.so looks like it is picking up the libmodbus correctly:
# ldd modbus.so
linux-gate.so.1 => (0xffffe000)
libmodbus.so.4 => /usr/lib/libmodbus.so.4 (0xb7ee1000)
libdl.so.2 => /lib/libdl.so.2 (0xb7edd000)
libc.so.6 => /lib/libc.so.6 (0xb7d9f000)
/lib/ld-linux.so.2 (0xb7ef4000)
Config for the plugin in the collectd.conf file is just a minor modification of the documented example:
<Plugin modbus>
<Data "voltage-input-1">
RegisterBase 0
RegisterType float
Type voltage
Instance "input-1"
</Data>
<Data "voltage-input-2">
RegisterBase 2
RegisterType float
Type voltage
Instance "input-2"
</Data>
<Host "10.1.2.2">
Address "10.1.2.2"
<Slave 1>
Instance "power-supply"
Collect "voltage-input-1"
</Slave>
</Host>
</Plugin>
Just wondering if anyone has managed to get modbus support working with the latest version?
Matt
More information about the collectd
mailing list