[collectd] compiling collectd-5.0.1 for iptables on CentOS 5.6

Manish Sapariya manish.sapariya at kpoint.com
Wed Jul 4 09:15:54 CEST 2012


Here is briefly the results of next steps.

After looking closely at the configure and
configure.in revealed that there is no file

./src/owniptc/ipt_kernel_headers.h

and the release notes confirms that the
shipped version support has been deprecated.

That means I need to have the iptables-devel
installed to get libiptc.

However as I mentioned in my earlier email
make fails with conflicting types.

To make progress, I modified the iptables.c
with following two defines

#define HAVE_IPTC_HANDLE_T 1
#define HAVE_IP6TC_HANDLE_T 1

which took me through compile, however stuck
at the link stage again with multiple definition
of TC_GET_RULE and others.

Is this a known issue?

Thanks and Regards,
Manish


On 7/3/2012 6:19 PM, Manish Sapariya wrote:
> my bad ...
>
> I am NOT able to get this one compiled.
>
> Thanks,
> Manish
>
>
> On 7/3/2012 6:13 PM, Manish Sapariya wrote:
>> Hi,
>> I am able to get this one compiled.
>>
>> I have following header files.
>>
>> -
>> /usr/src/kernels/2.6.18-238.el5-x86_64/include/linux/netfilter_ipv4/ip_tables.h
>>
>>
>> -
>> /usr/src/kernels/2.6.18-238.el5-x86_64/include/linux/netfilter_ipv6/ip6_tables.h
>>
>>
>> -
>> /usr/src/kernels/2.6.18-238.el5-x86_64/include/linux/netfilter/x_tables.h
>>
>> and I ran the configure after exporting
>>
>> export CPPFLAGS='-I /usr/src/kernels/2.6.18-238.el5-x86_64/include/'
>>
>>
>> But it still fails with the same message saying no (Linux iptables
>> headers not found)
>>
>> Could anyone please suggest anything else that I can try.
>>
>> Thanks and Regards,
>> Manish
>>
>>
>> On 6/25/2012 7:02 PM, Manish Sapariya wrote:
>>> Hi,
>>> I am trying to compile collectd-5.1.0 for libiptc for iptables
>>> monitoring, but not able to compile it successfully. I tried to
>>> apply the hints on the plugin page, but none of the following
>>> approach is giveing me result.
>>>
>>> * When I configure with default parameters it could not find libiptc
>>>      libiptc . . . . . . . no (pkg-config doesn't know libiptc)
>>>
>>> * If I configure collectd with
>>>     ./configure --with-libiptc=shipped
>>>    libiptc . . . . . . . no (Linux iptables headers not found)
>>>
>>> * If I configure collectd with
>>>
>>>   ./configure --with-libiptc=/usr/include/libiptc/
>>>
>>> the configuration is fine, but the make fails with following error.
>>> iptables.c:50: error: conflicting types for âiptc_handle_tâ
>>> /usr/include/libiptc/libiptc.h:29: error: previous declaration of
>>> âiptc_handle_tâ was here
>>> iptables.c:53: error: conflicting types for âip6tc_handle_tâ
>>> /usr/include/libiptc/libip6tc.h:21: error: previous declaration of
>>> âip6tc_handle_tâ was here
>>> cc1: warnings being treated as errors
>>>
>>> Can somebody point me to the method which works.
>>> Do I need the complete kernel sources to build this plugin?
>>>
>>> My environment:
>>>   - CentOS 5.6
>>>     - Linux one-567.gslab.com 2.6.18-238.el5 #1 SMP Thu Jan 13 15:51:15
>>> EST 2011 x86_64 x86_64 x86_64 GNU/Linux
>>>   - Packages
>>>     - iptables-1.3.5-5.3.el5_4.1
>>>     - iptables-devel-1.3.5-9.1.el5
>>>     - kernel-headers-2.6.18-238.el5
>>>     - kernel-devel-2.6.18-238.el5
>>>
>>> Appreciate any help, to get past this issue.
>>>
>>
>>
>> _______________________________________________
>> collectd mailing list
>> collectd at verplant.org
>> http://mailman.verplant.org/listinfo/collectd
>
>
> _______________________________________________
> collectd mailing list
> collectd at verplant.org
> http://mailman.verplant.org/listinfo/collectd




More information about the collectd mailing list