curl_json plugin: Remove unused field from cj_t.
Merge pull request #2279 from octo/ff/virt
virt plugin: Replace virTypedParamsFree() with virTypedParamsClear() …
virt plugin: Replace virTypedParamsFree() with virTypedParamsClear() …
virt plugin: Replace virTypedParamsFree() with virTypedParamsClear() and sfree().
The parameters are allocated with calloc(), freeing them with a library
function is unintuitive at best. Also, the library functions appears to
be missing the appropriate function attribute to tell clang / GCC that
it will free the pointer, resulting in a false-positive scan-build
report.
The parameters are allocated with calloc(), freeing them with a library
function is unintuitive at best. Also, the library functions appears to
be missing the appropriate function attribute to tell clang / GCC that
it will free the pointer, resulting in a false-positive scan-build
report.
Merge branch 'collectd-5.7'
Merge pull request #2275 from octo/ff/prometheus
write_prometheus plugin: Fix incorrect use of realloc().
write_prometheus plugin: Fix incorrect use of realloc().
Merge pull request #2274 from octo/ff/putval
src/utils_cmd_putval.c: Fix multi-value PUTVAL.
src/utils_cmd_putval.c: Fix multi-value PUTVAL.
src/utils_cmd_putval.c: Fix multi-value PUTVAL.
vl.values was allocated outside of the loop and then copied into each
ret_putval->vl[]. This means that later values overwrote the values
stored in previous ret_putval->vl[].
vl.values was allocated outside of the loop and then copied into each
ret_putval->vl[]. This means that later values overwrote the values
stored in previous ret_putval->vl[].
write_prometheus plugin: Fix incorrect use of realloc().
Calling realloc(ptr, 0) is undefined. Call free() explicitly.
Calling realloc(ptr, 0) is undefined. Call free() explicitly.
configure.ac: Remove empty else-block from AC_CHECK_LIB.
Fixes: #2272
Fixes: #2272
Merge branch 'collectd-5.7'
Merge branch 'collectd-5.6' into collectd-5.7
bind plugin: Use timegm() to convert to time_t if available.
FreeBSD doesn't provide the "extern long timezone", presumably because
it's "only" an XSI extension, leading to a portability issue with the
previous approach.
timegm() is a non-standard function available in GNU's and BSD's libc
which is doing exactly what we need. The previous code is left as a
fallback.
Fixes: #1268
FreeBSD doesn't provide the "extern long timezone", presumably because
it's "only" an XSI extension, leading to a portability issue with the
previous approach.
timegm() is a non-standard function available in GNU's and BSD's libc
which is doing exactly what we need. The previous code is left as a
fallback.
Fixes: #1268
fix BIND timezone parsing issue
collectd.conf(5): Add section documenting the ignorelist functionality.
Fixes: #2267
Fixes: #2267
Merge pull request #2265 from velotraveler/master
fix BIND timezone parsing issue
fix BIND timezone parsing issue
fix BIND timezone parsing issue
Merge pull request #2260 from bufadu/evol_redis
redis: adding support for keys count per database
redis: adding support for keys count per database
redis: fix parser and comments
redis: fixing maintainer requests
systemd.collectd.service: fix a typo
redis: removing sprintf() calls
redis: adding support for key count per database
Merge pull request #2255 from clemensg/sensors_support_current
sensors: support current values
sensors: support current values
sensors: support current values
Add support for current sensor data collection.
Signed-off-by: Clemens Gruber <clemensgru@gmail.com>
Add support for current sensor data collection.
Signed-off-by: Clemens Gruber <clemensgru@gmail.com>
Merge pull request #2252 from jaroug/kairosdb_ttl_support
Kairosdb ttl support
Kairosdb ttl support
fix spelling
Merge pull request #2253 from LionelCons/master
data-sets are in fact supported (issues#2244)
data-sets are in fact supported (issues#2244)
correct spelling
data-sets are in fact supported (issues#2244)
replace spaces by tabs
Add support for the new TTL parameter - kairosdb only
add documentation on the new TTL parameter
Merge branch 'collectd-5.7'
Merge branch 'collectd-5.6' into collectd-5.7
Tree-wide: remove last remnants of sizeof(char)
sizeof(char) is 1 by definition.
sizeof(char) is 1 by definition.
Merge pull request #2168 from maryamtahhan/feat_libvirt_upstream
virt: add support for new metrics
virt: add support for new metrics
Update mongodb write code to use latest API (Fixes: #492) (#2236)
Update mongodb write code to use latest API (Fixes: #492)
Update mongodb write code to use latest API (Fixes: #492)
Remove utils_ignorelist.[ch] from daemon; link plugins directly.
The collectd daemon isn't using the "ignorelist" functionality itself --
it was only linked in to provide it to loaded plugins. Since the code is
under the GPL, this interfers with our intend of having an MIT licensed
daemon.
This patch changes the build system to link plugins with the ignorelist
directly instead of expecting the symbols to be in the daemon.
The collectd daemon isn't using the "ignorelist" functionality itself --
it was only linked in to provide it to loaded plugins. Since the code is
under the GPL, this interfers with our intend of having an MIT licensed
daemon.
This patch changes the build system to link plugins with the ignorelist
directly instead of expecting the symbols to be in the daemon.
network plugin: Fix endless loop DOS in parse_packet()
When correct 'Signature part' is received by Collectd, configured without
AuthFile option, condition for endless loop occurs due to missing increase
of pointer to next unprocessed part.
This is a forward-port of #2233.
Fixes: CVE-2017-7401
Closes: #2174
Signed-off-by: Florian Forster <octo@collectd.org>
When correct 'Signature part' is received by Collectd, configured without
AuthFile option, condition for endless loop occurs due to missing increase
of pointer to next unprocessed part.
This is a forward-port of #2233.
Fixes: CVE-2017-7401
Closes: #2174
Signed-off-by: Florian Forster <octo@collectd.org>
Merge pull request #2051 from dsilakov/virt_list_domains
virt plugin: get domains using virConnectListAllDomains
virt plugin: get domains using virConnectListAllDomains
Merge pull request #1989 from rpv-tomsk/processes
processes plugin: Code cleanup + add per-process open files count
processes plugin: Code cleanup + add per-process open files count
processes plugin: collect per-process open files count on Linux
Closes: #836
Closes: #836
processes plugin: Update all counters via ps_update_counter()
Fix counting when matched processes are started and terminated often.
Fix counting when matched processes are started and terminated often.
processes plugin: Code cleanup
Merge pull request #2199 from jaroug/support_attributes_kairosdb
Add support for 'Attribute' option on KAIROSDB output format
Add support for 'Attribute' option on KAIROSDB output format
Merge pull request #2223 from maryamtahhan/intel_rdt_core_id_fix
intel_rdt: fix validation of configured core id values
intel_rdt: fix validation of configured core id values
Merge pull request #2225 from maryamtahhan/dpdstat_portmask_fix
dpdkstat: Enable all ports by default.
dpdkstat: Enable all ports by default.
dpdkstat: Enable all ports by default.
If "EnabledPortMask" option is not set
all DPDK ports will be monitored.
Signed-off-by: Taras Chornyi <tarasx.chornyi@intel.com>
If "EnabledPortMask" option is not set
all DPDK ports will be monitored.
Signed-off-by: Taras Chornyi <tarasx.chornyi@intel.com>
intel_rdt: fix validation of configured core id values
Change-Id: Ia009635c93e1cecd9852326b01c62fc6d2b090b5
Signed-off-by: Serhiy Pshyk <serhiyx.pshyk@intel.com>
Change-Id: Ia009635c93e1cecd9852326b01c62fc6d2b090b5
Signed-off-by: Serhiy Pshyk <serhiyx.pshyk@intel.com>
Merge pull request #2215 from maryamtahhan/dpdkstats_upstream
dpdkstat: doc updated with initialization time notice
dpdkstat: doc updated with initialization time notice
dpdkstat: doc updated with initialization time notice
Change-Id: Ia13c35e4112e74990896edb597d39c1f8ab14b6e
Signed-off-by: Krzysztof Matczak <krzysztofx.matczak@intel.com>
Change-Id: Ia13c35e4112e74990896edb597d39c1f8ab14b6e
Signed-off-by: Krzysztof Matczak <krzysztofx.matczak@intel.com>
Merge pull request #2210 from rpv-tomsk/processes-fix-init
processes plugin: Fix broken compilation on AIX
processes plugin: Fix broken compilation on AIX
Merge pull request #2213 from maryamtahhan/ovs_enable_platforms
ovs: enable only supported platforms (#2203)
ovs: enable only supported platforms (#2203)
ovs: enable only supported platforms
fixes GitHub issue #2203
Change-Id: I4d19b38b776f6b98fa3e4eb42e11b92dee7f8399
Signed-off-by: Mytnyk, VolodymyrX <volodymyrx.mytnyk@intel.com>
fixes GitHub issue #2203
Change-Id: I4d19b38b776f6b98fa3e4eb42e11b92dee7f8399
Signed-off-by: Mytnyk, VolodymyrX <volodymyrx.mytnyk@intel.com>
Merge pull request #2211 from maryamtahhan/feat_ovs_events_change_defaults
ovs_events: change configuration option defaults
ovs_events: change configuration option defaults
Merge pull request #2212 from maryamtahhan/ovs_events_scan_build
ovs_events: fixes issue #2205
ovs_events: fixes issue #2205
virt: add support for new metrics
Add support for new libvirt metrics:
- Performance monitoring events
- Domain state & reason
- Percentage CPU usage
- CPU pinning (affinity)
- Disk errors
- File system info
- Job stats
Change-Id: I233fb18653d218c7e906a157743606c6818f9feb
Signed-off-by: Przemyslaw Szczerbik <przemyslawx.szczerbik@intel.com>
Add support for new libvirt metrics:
- Performance monitoring events
- Domain state & reason
- Percentage CPU usage
- CPU pinning (affinity)
- Disk errors
- File system info
- Job stats
Change-Id: I233fb18653d218c7e906a157743606c6818f9feb
Signed-off-by: Przemyslaw Szczerbik <przemyslawx.szczerbik@intel.com>
ovs_events: fix scan-build warnings #2205
src/utils_ovs.c:366:20: warning: Access to field 'type' results in a dereference of a null pointer (loaded from variable 'jval')
(int)(jval)->type);
^~~~~~~~~~~~
...
Change-Id: Ic856d21f2121f920bdd2043c69620555bb3d1cb8
Signed-off-by: Mytnyk, VolodymyrX <volodymyrx.mytnyk@intel.com>
src/utils_ovs.c:366:20: warning: Access to field 'type' results in a dereference of a null pointer (loaded from variable 'jval')
(int)(jval)->type);
^~~~~~~~~~~~
...
Change-Id: Ic856d21f2121f920bdd2043c69620555bb3d1cb8
Signed-off-by: Mytnyk, VolodymyrX <volodymyrx.mytnyk@intel.com>
ovs_events: change configuration option defaults
Right now, the plugin dispatches values by default and doesn't send
any notification messages. The expected behaviour of the event plugin
is to send notification by default. So, changed default value of
SendNotification & DispatchValues options to opposite.
Change-Id: I908799da1b2e75d2089765769ce56af00246c440
Signed-off-by: Mytnyk, VolodymyrX <volodymyrx.mytnyk@intel.com>
Right now, the plugin dispatches values by default and doesn't send
any notification messages. The expected behaviour of the event plugin
is to send notification by default. So, changed default value of
SendNotification & DispatchValues options to opposite.
Change-Id: I908799da1b2e75d2089765769ce56af00246c440
Signed-off-by: Mytnyk, VolodymyrX <volodymyrx.mytnyk@intel.com>
processes plugin: Fix broken compilation on AIX
After a bb0000acfc57e230fc1c26099bc7acb913680f1a an extra pse.cpu_system
statement was left in the AIX / elif HAVE_PROCINFO_H section, which caused
the compilation to fail.
Fixes: #1981
After a bb0000acfc57e230fc1c26099bc7acb913680f1a an extra pse.cpu_system
statement was left in the AIX / elif HAVE_PROCINFO_H section, which caused
the compilation to fail.
Fixes: #1981
Merge pull request #2207 from maryamtahhan/fix_for_2201
ovs_stats: Increase devname buffer
ovs_stats: Increase devname buffer
Increase devname buffer buffer to ensure that snprintf output
would not be truncated before the last format character
Signed-off-by: Taras Chornyi <tarasx.chornyi@intel.com>
would not be truncated before the last format character
Signed-off-by: Taras Chornyi <tarasx.chornyi@intel.com>
collectd.spec: move new plugins to subpackages
collectd.spec: add ovs_stats plugin
virt plugin: fix build warning
CC src/virt_la-virt.lo
src/virt.c:417:37: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare]
if ((tag_index < 0) || (tag_index >= STATIC_ARRAY_SIZE(tags))) {
~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
CC src/virt_la-virt.lo
src/virt.c:417:37: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare]
if ((tag_index < 0) || (tag_index >= STATIC_ARRAY_SIZE(tags))) {
~~~~~~~~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~
1 warning generated.
Merge branch 'collectd-5.7'
Conflicts:
contrib/redhat/collectd.spec
Conflicts:
contrib/redhat/collectd.spec
Merge branch 'collectd-5.6' into collectd-5.7
Conflicts:
contrib/redhat/collectd.spec
Conflicts:
contrib/redhat/collectd.spec
collectd.spec: Don't enable XFS support on RHEL6
It is missing for i386.
If there's strong interest in having support for xfs in the df plugin in
RHEL6 we can do some macro magic to only BuildRequire xfsprogs-devel if
were not on rhel6 i386, but this was the easiest fix and unblocks our
package builds.
It is missing for i386.
If there's strong interest in having support for xfs in the df plugin in
RHEL6 we can do some macro magic to only BuildRequire xfsprogs-devel if
were not on rhel6 i386, but this was the easiest fix and unblocks our
package builds.
spec: Don't enable XFS support on RHEL6
It is missing for i386.
It is missing for i386.
Add dpkdevents plugin to spec file
utils_cmd_flush.c: fix another build warning
src/utils_cmd_flush.c:140:11: warning: declaration shadows a local variable [-Wshadow]
int status;
^
src/utils_cmd_flush.c:114:7: note: previous declaration is here
int status;
^
src/utils_cmd_flush.c:140:11: warning: declaration shadows a local variable [-Wshadow]
int status;
^
src/utils_cmd_flush.c:114:7: note: previous declaration is here
int status;
^
utils_cmd_flush.c: fix build warning
CC src/utils_cmd_flush.lo
src/utils_cmd_flush.c:139:12: warning: declaration shadows a local variable [-Wshadow]
char buffer[1024];
^
src/utils_cmd_flush.c:108:47: note: previous declaration is here
cmd_status_t cmd_handle_flush(FILE *fh, char *buffer) {
^
CC src/utils_cmd_flush.lo
src/utils_cmd_flush.c:139:12: warning: declaration shadows a local variable [-Wshadow]
char buffer[1024];
^
src/utils_cmd_flush.c:108:47: note: previous declaration is here
cmd_status_t cmd_handle_flush(FILE *fh, char *buffer) {
^
ovs_stats plugin: fix some more build warnings
CC src/ovs_stats_la-ovs_stats.lo
src/ovs_stats.c:158:8: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
static const iface_counter ovs_stats_counter_name_to_type(const char *counter) {
^~~~~~
src/ovs_stats.c:356:29: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < ports_num; i++)
~ ^ ~~~~~~~~~
src/ovs_stats.c:401:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(bridges)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:415:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(bridges)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:501:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(ports)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:524:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(ports)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:538:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_ARRAY(stats)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:558:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_ARRAY(ext_ids)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:684:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(ports)->len; i++)
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
9 warnings generated.
CC src/ovs_stats_la-ovs_stats.lo
src/ovs_stats.c:158:8: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
static const iface_counter ovs_stats_counter_name_to_type(const char *counter) {
^~~~~~
src/ovs_stats.c:356:29: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < ports_num; i++)
~ ^ ~~~~~~~~~
src/ovs_stats.c:401:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(bridges)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:415:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(bridges)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:501:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(ports)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:524:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(ports)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:538:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_ARRAY(stats)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:558:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_ARRAY(ext_ids)->len; i++) {
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/ovs_stats.c:684:23: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
for (int i = 0; i < YAJL_GET_OBJECT(ports)->len; i++)
~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~
9 warnings generated.
ovs_stats plugin: fix build warning
src/ovs_stats.c:158:8: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
static const iface_counter ovs_stats_counter_name_to_type(const char *counter) {
^~~~~~
src/ovs_stats.c:158:8: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
static const iface_counter ovs_stats_counter_name_to_type(const char *counter) {
^~~~~~
Merge branch 'collectd-5.7'
Conflicts:
configure.ac
Conflicts:
configure.ac
Merge branch 'collectd-5.6' into collectd-5.7
Merge pull request #2204 from collectd/check-for-cap-is-supported
Check for the CAP_IS_SUPPORTED macro
Check for the CAP_IS_SUPPORTED macro
Check for the CAP_IS_SUPPORTED macro
On EPEL6:
src/daemon/common.c: In function 'check_capability':
src/daemon/common.c:1571: error: implicit declaration of function 'CAP_IS_SUPPORTED'
make[1]: *** [src/daemon/common.lo] Error 1
On EPEL6:
src/daemon/common.c: In function 'check_capability':
src/daemon/common.c:1571: error: implicit declaration of function 'CAP_IS_SUPPORTED'
make[1]: *** [src/daemon/common.lo] Error 1
Merge branch 'master' into virt_list_domains
fix spelling again
fix spelling
switch back 'http_attrs_num' to type size_t
remove unnecessary newline
add support for new parameter 'Attribute'
add doc on new parameter 'Attribute'
optional parameter 'Attribute' for kairosdb
Merge pull request #2137 from maryamtahhan/feat_ovs_stats
ovs_stats: Implement OVS statistics plugin.
ovs_stats: Implement OVS statistics plugin.
Merge branch 'collectd-5.7'
Conflicts:
configure.ac
Conflicts:
configure.ac
Merge branch 'collectd-5.6' into collectd-5.7
look for cap_get_proc instead of cap_get_bound
a2ddc38 switched the capability check from cap_get_bound() to
cap_get_proc()
a2ddc38 switched the capability check from cap_get_bound() to
cap_get_proc()
Merge pull request #2151 from mfournier/check_capability-rewrite-fix
daemon/common.c: Fix check_capability() by using cap_get_proc()
daemon/common.c: Fix check_capability() by using cap_get_proc()
Merge branch 'collectd-5.7'
Merge branch 'collectd-5.6' into collectd-5.7
Conflicts:
src/utils_match.c
Conflicts:
src/utils_match.c
smart: log warning if CAP_SYS_RAWIO is missing
Related to #2143
Related to #2143
Merge pull request #2157 from maryamtahhan/dpdkevents_upstream
Plugin for getting DPDK ports link status and keep alive events.
Plugin for getting DPDK ports link status and keep alive events.
Merge pull request #2192 from maryamtahhan/bugfix_regex_memleak
fix for memory leak in utils_match.c
fix for memory leak in utils_match.c
Merge pull request #2194 from maryamtahhan/feat_dpdkstat_fix
dpdkstat: fix retrieval of statistics
dpdkstat: fix retrieval of statistics
dpdkstat: fix retrieval of statistics
This change forces dpdkstat plugin to check if memory needs to be resized on
every DPDK_CMD_GET_STATS command, rather than resizing it only once at
initialization. Additionally it fixes incorrect metric retrieval logic, which
allows plugin to dispatch metrics only if number of retrieved extended statistics
is equal to allocated stats array size for port. Based on DPDK API documentation
rte_eth_xstats_get (and rte_eth_xstats_get_names) function can return positive
value lower than array size, which isn't considered a failure.
If primary DPDK process is restarted with a greater number of ports bound to
DPDK driver while collectd dpdkstat plugin is running, then memory isn't resized.
Due to insufficient memory allocation dpdkstat plugin is unable to gather metrics
from new ports.
Change-Id: I25c8995105a322474653bf7065c2228047f886b1
Signed-off-by: Przemyslaw Szczerbik <przemyslawx.szczerbik@intel.com>
This change forces dpdkstat plugin to check if memory needs to be resized on
every DPDK_CMD_GET_STATS command, rather than resizing it only once at
initialization. Additionally it fixes incorrect metric retrieval logic, which
allows plugin to dispatch metrics only if number of retrieved extended statistics
is equal to allocated stats array size for port. Based on DPDK API documentation
rte_eth_xstats_get (and rte_eth_xstats_get_names) function can return positive
value lower than array size, which isn't considered a failure.
If primary DPDK process is restarted with a greater number of ports bound to
DPDK driver while collectd dpdkstat plugin is running, then memory isn't resized.
Due to insufficient memory allocation dpdkstat plugin is unable to gather metrics
from new ports.
Change-Id: I25c8995105a322474653bf7065c2228047f886b1
Signed-off-by: Przemyslaw Szczerbik <przemyslawx.szczerbik@intel.com>
fix for memory leak in utils_match.c
Change-Id: I058afae8c0a99115bda70e125840fc6bd224b358
Signed-off-by: Krzysztof Matczak <krzysztofx.matczak@intel.com>
Change-Id: I058afae8c0a99115bda70e125840fc6bd224b358
Signed-off-by: Krzysztof Matczak <krzysztofx.matczak@intel.com>
dpdkevents: PR comments addressed
RTE version check changed to compile time. Adressing PR
review comments. Minor format changes
Change-Id: Ie345a6009a291490323f614183362dfce8e6a5e6
RTE version check changed to compile time. Adressing PR
review comments. Minor format changes
Change-Id: Ie345a6009a291490323f614183362dfce8e6a5e6