Merge pull request #811 from mfournier/systemd-upstart-build-issue
prevent going through systemd/upstart code, except on Linux
prevent going through systemd/upstart code, except on Linux
Merge pull request #810 from njh/mac_battery_read_return
Added return (0) to the Mac/IOKit variant of battery_read()
Added return (0) to the Mac/IOKit variant of battery_read()
prevent going through systemd/upstart code, except on Linux
Fixes #809 (build issue on MacOSX)
NB: in case one day upstart is used on non-Linux platforms, this could
be relaxed to only skip systemd.
Fixes #809 (build issue on MacOSX)
NB: in case one day upstart is used on non-Linux platforms, this could
be relaxed to only skip systemd.
Added return(0) to the Mac/IOKit variant of battery_read()
Merge pull request #806 from vincentbernat/fix/libstatgrab2
libstatgrab: only use one configure test for 0.90 API change
libstatgrab: only use one configure test for 0.90 API change
Merge pull request #808 from landryb/openbsd_build_fixes_2
Openbsd build fixes 2
Openbsd build fixes 2
Detect sys/vmmeter.h and include it if available.
Needed on OpenBSD for struct vmtotal definition.
Needed on OpenBSD for struct vmtotal definition.
libstatgrab: only use one configure test for 0.90 API change
Previously, each API change was tested in configure.ac. Some of the
tests are relying on signature checks and would need to have -Werror
flag enabled to make them work. This is quite fragile.
Instead, we assume that if `sg_init()` requires an argument, we must use
the 0.90 API.
Fixes: #795
Previously, each API change was tested in configure.ac. Some of the
tests are relying on signature checks and would need to have -Werror
flag enabled to make them work. This is quite fragile.
Instead, we assume that if `sg_init()` requires an argument, we must use
the 0.90 API.
Fixes: #795
RPM specfile: add support for smart & openldap plugins
add credits for new plugins
smart: mention support lib in README
adapt contrib script
Merge pull request #719 from mfournier/openldap-improvements-rebased
Openldap plugin
Openldap plugin
Merge pull request #795 from vincentbernat/fix/libstatgrab
libstatgrab: fix sg_init() invocation for libstatgrab >= 0.9
libstatgrab: fix sg_init() invocation for libstatgrab >= 0.9
Merge pull request #797 from vincentbernat/feature/libatasmart
smart: add a SMART plugin
smart: add a SMART plugin
Merge pull request #800 from pyr/feature/riemann-batch
Add a batching mechanism for riemann TCP writes
Add a batching mechanism for riemann TCP writes
Merge pull request #798 from pyr/feature/upstart-job
Support both systemd and upstart.
Support both systemd and upstart.
libstatgrab: fix sg_get_disk_io_stats() invocation for libstatgrab >= 0.9
In those versions, `sg_get_disk_io_stats()` need to be invoked a pointer
to size_t instead of pointer to int. Such a requirement is detected at
configure-time.
Fixes: #445
In those versions, `sg_get_disk_io_stats()` need to be invoked a pointer
to size_t instead of pointer to int. Such a requirement is detected at
configure-time.
Fixes: #445
openldap: add mention in README
openldap: relicence to MIT
... with Kimo's agreement. Also add myself to copyright holders.
... with Kimo's agreement. Also add myself to copyright holders.
smart: when threshold is valid, also test for "less or equal"
When the threshold is 0, a value of 0 should hit the threshold.
When the threshold is 0, a value of 0 should hit the threshold.
libstatgrab: fix sg_get_user_stats() invocation for libstatgrab >= 0.9
In those versions, `sg_get_user_stats()` need to be invoked with an
additional argument. The need for such an argument is detected at
configure-time.
Fixes: #445
In those versions, `sg_get_user_stats()` need to be invoked with an
additional argument. The need for such an argument is detected at
configure-time.
Fixes: #445
libstatgrab: fix sg_init() invocation for libstatgrab >= 0.9
In those versions, `sg_init()` need to be invoked with an additional
argument. The need for such an argument is detected at configure-time.
Fixes: #445
In those versions, `sg_init()` need to be invoked with an additional
argument. The need for such an argument is detected at configure-time.
Fixes: #445
Merge pull request #803 from bnordbo/aggregation-libm
Link aggregation.so to libm.so
Link aggregation.so to libm.so
Link aggregation.so to libm.so
Add a batching mechanism for riemann TCP writes
This does not batch notifications.
This does not batch notifications.
Merge pull request #793 from vincentbernat/fix/gcrypt-deprecated
network: don't enable gcrypt thread callbacks when gcrypt recent enough
network: don't enable gcrypt thread callbacks when gcrypt recent enough
Merge pull request #792 from vincentbernat/fix/out-of-tree-build
build: fix out-of-tree build
build: fix out-of-tree build
Support both systemd and upstart.
This checks appropriate environment variables. When supervised
by either upstart or systemd, collectd will not daemonize but
will signal readyness with the appropriate method.
This allows collectd to be either configured with `expect stop`
in upstart or `Type=notify` with systemd.
The rationale for this is detailed here: http://spootnik.org/entries/2014/11/09_pid-tracking-in-modern-init-systems.html
This checks appropriate environment variables. When supervised
by either upstart or systemd, collectd will not daemonize but
will signal readyness with the appropriate method.
This allows collectd to be either configured with `expect stop`
in upstart or `Type=notify` with systemd.
The rationale for this is detailed here: http://spootnik.org/entries/2014/11/09_pid-tracking-in-modern-init-systems.html
smart: add notifications when a value is below the threshold
smart: add a SMART plugin
This plugin uses libatasmart:
http://0pointer.de/blog/projects/being-smart.html
As libatasmart is Linux-only, the plugin is therefore Linux-only
too. The disks are discovered through libudev.
Each SMART attribute is extracted. The current value, worst value,
threshold value (if any) are recorded. Those are normalized
values (between 0 and 255, higher is better). For some values, it makes
more sense to record the raw value. libatasmart is converting this raw
value to something sensible. We record that form. Sometimes, this is
just the raw value but sometimes this is converted to another scale (for
example, the temperature). People should know what each attribute means
before using those values. Otherwise, the normalized values are better.
Four values are (power-on time, power cycle count, bad sectors and
temperature) are also recorded on their own. Those are usually the
values that the user care about the most.
Here is an excerpt of the plugin output with the CSV plugin (the SSD
disk on my laptop doesn't provide a temperature sensor):
.
└── zoro.exoscale.ch
└── smart-sda
├── smart_attribute-attribute-173-2014-11-10
├── smart_attribute-attribute-174-2014-11-10
├── smart_attribute-available-reserved-space-2014-11-10
├── smart_attribute-end-to-end-error-2014-11-10
├── smart_attribute-erase-fail-count-2014-11-10
├── smart_attribute-power-cycle-count-2014-11-10
├── smart_attribute-power-on-hours-2014-11-10
├── smart_attribute-power-on-seconds-2-2014-11-10
├── smart_attribute-program-fail-count-2014-11-10
├── smart_attribute-reallocated-sector-count-2014-11-10
├── smart_attribute-reported-uncorrect-2014-11-10
├── smart_attribute-total-lbas-read-2014-11-10
├── smart_attribute-total-lbas-written-2014-11-10
├── smart_attribute-udma-crc-error-count-2014-11-10
├── smart_attribute-unused-reserved-blocks-2014-11-10
├── smart_attribute-used-reserved-blocks-chip-2014-11-10
├── smart_badsectors-2014-11-10
├── smart_powercycles-2014-11-10
└── smart_poweron-2014-11-10
$ cat zoro.exoscale.ch/smart-sda/smart_attribute-total-lbas-read-2014-11-10
epoch,current,worst,threshold,pretty
1415613266.376,100.000000,100.000000,0.000000,281018.000000
1415613276.395,100.000000,100.000000,0.000000,281018.000000
1415613286.384,100.000000,100.000000,0.000000,281051.000000
1415613296.383,100.000000,100.000000,0.000000,281051.000000
This plugin uses libatasmart:
http://0pointer.de/blog/projects/being-smart.html
As libatasmart is Linux-only, the plugin is therefore Linux-only
too. The disks are discovered through libudev.
Each SMART attribute is extracted. The current value, worst value,
threshold value (if any) are recorded. Those are normalized
values (between 0 and 255, higher is better). For some values, it makes
more sense to record the raw value. libatasmart is converting this raw
value to something sensible. We record that form. Sometimes, this is
just the raw value but sometimes this is converted to another scale (for
example, the temperature). People should know what each attribute means
before using those values. Otherwise, the normalized values are better.
Four values are (power-on time, power cycle count, bad sectors and
temperature) are also recorded on their own. Those are usually the
values that the user care about the most.
Here is an excerpt of the plugin output with the CSV plugin (the SSD
disk on my laptop doesn't provide a temperature sensor):
.
└── zoro.exoscale.ch
└── smart-sda
├── smart_attribute-attribute-173-2014-11-10
├── smart_attribute-attribute-174-2014-11-10
├── smart_attribute-available-reserved-space-2014-11-10
├── smart_attribute-end-to-end-error-2014-11-10
├── smart_attribute-erase-fail-count-2014-11-10
├── smart_attribute-power-cycle-count-2014-11-10
├── smart_attribute-power-on-hours-2014-11-10
├── smart_attribute-power-on-seconds-2-2014-11-10
├── smart_attribute-program-fail-count-2014-11-10
├── smart_attribute-reallocated-sector-count-2014-11-10
├── smart_attribute-reported-uncorrect-2014-11-10
├── smart_attribute-total-lbas-read-2014-11-10
├── smart_attribute-total-lbas-written-2014-11-10
├── smart_attribute-udma-crc-error-count-2014-11-10
├── smart_attribute-unused-reserved-blocks-2014-11-10
├── smart_attribute-used-reserved-blocks-chip-2014-11-10
├── smart_badsectors-2014-11-10
├── smart_powercycles-2014-11-10
└── smart_poweron-2014-11-10
$ cat zoro.exoscale.ch/smart-sda/smart_attribute-total-lbas-read-2014-11-10
epoch,current,worst,threshold,pretty
1415613266.376,100.000000,100.000000,0.000000,281018.000000
1415613276.395,100.000000,100.000000,0.000000,281018.000000
1415613286.384,100.000000,100.000000,0.000000,281051.000000
1415613296.383,100.000000,100.000000,0.000000,281051.000000
ignore new dirs
Define _DEFAULT_SOURCE in addition to _BSD_SOURCE
This enables forward compatibility with the ongoing
deprecation of _BSD_SOURCE.
This enables forward compatibility with the ongoing
deprecation of _BSD_SOURCE.
Merge pull request #794 from vincentbernat/fix/kafka-warning
kafka: fix compilation for older versions of librdkafka
kafka: fix compilation for older versions of librdkafka
kafka: fix compilation for older versions of librdkafka
Since commit f505691270f2317291c372fd5f004a4ffbce9f9a, kafka module was
broken. Enable definition of `kafka_log()` when using kafka logger
callback as well.
Since commit f505691270f2317291c372fd5f004a4ffbce9f9a, kafka module was
broken. Enable definition of `kafka_log()` when using kafka logger
callback as well.
network: don't enable gcrypt thread callbacks when gcrypt recent enough
From `gcrypt.h`:
> NOTE: Since Libgcrypt 1.6 the thread callbacks are not anymore used.
> However we keep it to allow for some source code compatibility if used
> in the standard way.
Otherwise, we get a deprecation warning which is turned into an error:
```
CC libcollectdclient_la-network_buffer.lo
../../../src/libcollectdclient/network_buffer.c:58:15: error: 'gcry_thread_cbs' is deprecated (declared at /usr/include/gcrypt.h:213) [-Werror=deprecated-declarations]
GCRY_THREAD_OPTION_PTHREAD_IMPL;
```
Fixes: #632
From `gcrypt.h`:
> NOTE: Since Libgcrypt 1.6 the thread callbacks are not anymore used.
> However we keep it to allow for some source code compatibility if used
> in the standard way.
Otherwise, we get a deprecation warning which is turned into an error:
```
CC libcollectdclient_la-network_buffer.lo
../../../src/libcollectdclient/network_buffer.c:58:15: error: 'gcry_thread_cbs' is deprecated (declared at /usr/include/gcrypt.h:213) [-Werror=deprecated-declarations]
GCRY_THREAD_OPTION_PTHREAD_IMPL;
```
Fixes: #632
build: fix out-of-tree build
When building collectd out of tree, `srcdir` and `builddir` are
different. We ask to search path in `$(top_srcdir)/src` since this is
needed to find `liboconfig/config.h`. Also fix search path for
libcollectdclient where only one header is in `builddir` while the
remaining are in `srcdir`.
When building collectd out of tree, `srcdir` and `builddir` are
different. We ask to search path in `$(top_srcdir)/src` since this is
needed to find `liboconfig/config.h`. Also fix search path for
libcollectdclient where only one header is in `builddir` while the
remaining are in `srcdir`.
Merge pull request #791 from mfournier/fix-lvm-merge-conflict-mistake
lvm: remove duplicate call to lvm_submit()
lvm: remove duplicate call to lvm_submit()
lvm: remove duplicate call to lvm_submit()
This got added by accident when solving the merge conflict in 103f05e0.
It led to the plugin triggering the classical "uc_update: Value too old"
error message.
This got added by accident when solving the merge conflict in 103f05e0.
It led to the plugin triggering the classical "uc_update: Value too old"
error message.
Merge pull request #772 from mschenck/write_tsdb-type-type_instance-differentiate
Including vl->type, even when vl->type_instance is available to avoid ov...
Including vl->type, even when vl->type_instance is available to avoid ov...
Merge pull request #778 from landryb/openbsd_fix_processes_plugin
Fix the processes plugin on OpenBSD (#776)
Fix the processes plugin on OpenBSD (#776)
Merge pull request #779 from landryb/openbsd_build_fixes
Openbsd build fixes
Openbsd build fixes
Recent NetBSD versions also use a TAILQ.
10 years agoUse cpu_stage() where expected in the CAN_USE_SYSCTL, HAVE_LIBSTATGRAB and HAVE_SYSCT...
Use cpu_stage() where expected in the CAN_USE_SYSCTL, HAVE_LIBSTATGRAB and HAVE_SYSCTLBYNAME codepaths.
cpu_state() isnt a function.
cpu_state() isnt a function.
inpt_queue is a TAILQ on OpenBSD
Link collectd-tg with -lpthread if available
otherwise linking fails with undefined refs to pthread_mutex_* functions
otherwise linking fails with undefined refs to pthread_mutex_* functions
Fix swapctl() argument count detection on OpenBSD.
on OpenBSD swapctl() takes three arguments, but is defined in unistd.h
and also needs sys/param.h.
http://www.openbsd.org/cgi-bin/man.cgi/OpenBSD-current/man2/swapctl.2
we need to add those headers to both detections to make sure the test
on 'swapctl takes two arguments' correctly fails.
on OpenBSD swapctl() takes three arguments, but is defined in unistd.h
and also needs sys/param.h.
http://www.openbsd.org/cgi-bin/man.cgi/OpenBSD-current/man2/swapctl.2
we need to add those headers to both detections to make sure the test
on 'swapctl takes two arguments' correctly fails.
Include pthread.h in plugin.h to get pthread_t definition.
Fix the processes plugin on OpenBSD (#776)
Properly check for struct kinfo_proc members in configure.ac
Use kvm_getprocs() like it was done on FreeBSD
Properly check for struct kinfo_proc members in configure.ac
Use kvm_getprocs() like it was done on FreeBSD
Merge remote-tracking branch 'origin/pr/488'
Let the config parser accept unquoted IPv6 addresses.
The parser supports raw IPv6 addresses, optional address and port (as
[<addr>]:<port>), and embedded IPv4 addresses.
Based on "Common Patterns" found in the flex manual.
The parser supports raw IPv6 addresses, optional address and port (as
[<addr>]:<port>), and embedded IPv4 addresses.
Based on "Common Patterns" found in the flex manual.
Merge pull request #774 from trenkel/master
Adding get_dataset() to python
Adding get_dataset() to python
python: Add get_dataset() to the man page.
Add get_dataset() as a way to get the definition of a dataset from python.
https://github.com/collectd/collectd/issues/771
https://github.com/collectd/collectd/issues/771
Including vl->type, even when vl->type_instance is available to avoid over-writing values (i.e. with the 'df' plugin)
mysql: correct 2 data types in innodb counters
Thanks to @ekilby for spotting this mistake ! Fixes #757
Thanks to @ekilby for spotting this mistake ! Fixes #757
Merge pull request #751 from ptbrowne/prepend-sys-path
feat(python-plugin): prepend instead of append ModulePath to sys.path
feat(python-plugin): prepend instead of append ModulePath to sys.path
doc(collectd-python): update
feat(python-plugin): prepend instead of append ModulePath to sys.path
When importing a module, you expect the plugin repertory to have higher priority
than your site-packages. It will prevent hard to debug clashing module names problems.
At least, if there is a problem, it will fail more loudly than "module did not register
any config callback"
When importing a module, you expect the plugin repertory to have higher priority
than your site-packages. It will prevent hard to debug clashing module names problems.
At least, if there is a problem, it will fail more loudly than "module did not register
any config callback"
cpu plugin: Don't report empty cpu states.
src/Makefile.am: Make sure plugins only export "module_register".
While there, put the LDFLAGS shared between all plugins into a separate
variable.
While there, put the LDFLAGS shared between all plugins into a separate
variable.
Merge remote-tracking branch 'github/pr/697'
Merge remote-tracking branch 'github/pr/734'
bind plugin: split bind_xml_stats to v3 and v1_v2.
And minor change to bind_parse_generic_name_attr_value_list.
And minor change to bind_parse_generic_name_attr_value_list.
bind plugin: add support for the new XML v3 API.
Unfortunately, this new API does not provide per-zone data
any more, thus 'Zone' options like
Zone "example.com/IN"
are ignored if API version is 3.
Unfortunately, this new API does not provide per-zone data
any more, thus 'Zone' options like
Zone "example.com/IN"
are ignored if API version is 3.
COPYING: Add the MIT License and add a note about plugins being licensed individually.
Move utils_parse_option.[ch] out of the daemon/ directory.
common.[ch]: Move escape_string() to here.
Move collectd daemon files to the src/daemon/ directory.
memory: make linux slab reporting work with older kernels
memory: adjust safeguard to changes from previous commit
src/collectd.c: Set the LC_NUMERIC locale to "C".
When using ASCII protocols, such as the Graphite protocol, doubles are
converted to strings using sprintf(3) and parsed with strtod(3). If the
effective locale uses something different from a dot (".") as the
decimal separator (e.g. Portuguese, German), this breaks.
This patch sets the LC_NUMERIC locale to "C" on start-up, so that
strings are produced and parsed in a well-defined manner.
Fixes: #512
When using ASCII protocols, such as the Graphite protocol, doubles are
converted to strings using sprintf(3) and parsed with strtod(3). If the
effective locale uses something different from a dot (".") as the
decimal separator (e.g. Portuguese, German), this breaks.
This patch sets the LC_NUMERIC locale to "C" on start-up, so that
strings are produced and parsed in a well-defined manner.
Fixes: #512
write_graphite plugin: Limit number of reconnection attempts per time.
Fixes: #625
Fixes: #625
memory plugin: Add slab memory stats (linux)
Pull-Request: #560
Pull-Request: #560
virt plugin: Rename the "libvirt" plugin to "virt".
"libvirt" confused libtool and caused problems when re-building from source.
"libvirt" confused libtool and caused problems when re-building from source.
cpu plugin: Various, random fixes and improvements:
* Add Pierre-Yves to the list of copyright holders.
* Make sure the entire file is consistently indented.
* Renamed the "ReportActive" config option to "ReportByState"
(with negated logic).
* Renamed internal functions to better reflect their use.
* Let cpu_stage() (née submit()) work on individual counters / derives
rather than an array, removing logic from the cpu_read() function.
* Rename CPU_SUBMIT_* to CPU_STATE_*.
* Move legacy behavior it its own function, cpu_commit_without_aggregation().
* Add Pierre-Yves to the list of copyright holders.
* Make sure the entire file is consistently indented.
* Renamed the "ReportActive" config option to "ReportByState"
(with negated logic).
* Renamed internal functions to better reflect their use.
* Let cpu_stage() (née submit()) work on individual counters / derives
rather than an array, removing logic from the cpu_read() function.
* Rename CPU_SUBMIT_* to CPU_STATE_*.
* Move legacy behavior it its own function, cpu_commit_without_aggregation().
swap plugin: Make SwapCached optional under Linux.
OpenVZ doesn't provide the line, which caused swap collection to be
skipped entirely on these systems. Instead, "cached" should simply be
ignored, as it is on other systems. Thanks to @zerkms for reporting this
problem!
Fixes: #733
OpenVZ doesn't provide the line, which caused swap collection to be
skipped entirely on these systems. Instead, "cached" should simply be
ignored, as it is on other systems. Thanks to @zerkms for reporting this
problem!
Fixes: #733
cpu plugin: Fix parsing of SoftIRQ under Linux.
openvpn plugin: Don't signal an error when no clients are connected.
In the multi1_read() function, an error (zero) was returned when no
clients were currently connected to the OpenVPN server, because the
"read" variable was initialized to zero and the while loop exited before
it was set to one. This is not the intended behavior.
Thanks to @srix for reporting this issue!
Fixes: #731
In the multi1_read() function, an error (zero) was returned when no
clients were currently connected to the OpenVPN server, because the
"read" variable was initialized to zero and the while loop exited before
it was set to one. This is not the intended behavior.
Thanks to @srix for reporting this issue!
Fixes: #731
Add ReconnectInterval option to Network plugin
The Network plugin only performs DNS resolution at initialization. This
can be problematic when trying to performs migrations of collectd
infrastructure or when trying to create HA solutions which are dependant
on DNS.
The ReconnectInterval options forces a reconnect of all the sockets at
the defined number of seconds. By default no re-connections are attempted
if this option is not set.
The Network plugin only performs DNS resolution at initialization. This
can be problematic when trying to performs migrations of collectd
infrastructure or when trying to create HA solutions which are dependant
on DNS.
The ReconnectInterval options forces a reconnect of all the sockets at
the defined number of seconds. By default no re-connections are attempted
if this option is not set.
Move sockent_client_disconnect above sockent_client_disconnect so we can use it there
collectd.conf(5): Document the ReportDegraded" option.
battery plugin: Implement the "ReportDegraded" option.
battery plugin: Implement the ValuesPercentage option.
battery plugin: Only report "current" when actually supplied by the battery.
I think the commend in the file sums it up pretty good, read that ;)
I think the commend in the file sums it up pretty good, read that ;)
AUTHORS: Add Andy Parkins.
Fix typo in if caluse
Fixes #729
Fixes #729
battery plugin: Import code to read metrics from sysfs.
This started as a simple import of Andy Parkins' sysfsbattery plugin into
the battery plugin. Since the battery plugin is ancient and hasn't been
touched in a while, this quickly escalated to a much bigger refactoring.
Sorry!
On the other hand, this fixes a couple of bugs. For example, all metrics
were always dispatched with plugin_instance "0". This is correct for the
majority of laptops, of course, but in theory this could be wrong.
Also ACPI charging / discharging rate is reported as "current", when
modern batteries actually report "power". The sysfs code does this
correctly, ACPI still needs to be patched.
Fixes: #725
This started as a simple import of Andy Parkins' sysfsbattery plugin into
the battery plugin. Since the battery plugin is ancient and hasn't been
touched in a while, this quickly escalated to a much bigger refactoring.
Sorry!
On the other hand, this fixes a couple of bugs. For example, all metrics
were always dispatched with plugin_instance "0". This is correct for the
majority of laptops, of course, but in theory this could be wrong.
Also ACPI charging / discharging rate is reported as "current", when
modern batteries actually report "power". The sysfs code does this
correctly, ACPI still needs to be patched.
Fixes: #725
src/common.[ch]: Implement strtogauge().
src/configfile.c: Fix the default interval setting.
Also fixes a bug in global_option_get_time(): Values smaller than or
equal to zero are illegal and the default value should be returned.
Thanks to @anandkarthik for spotting this!
Fixes: #727
Also fixes a bug in global_option_get_time(): Values smaller than or
equal to zero are illegal and the default value should be returned.
Thanks to @anandkarthik for spotting this!
Fixes: #727
RPM specfile: take all new plugins and dependencies in account
Merge branch 'collectd-5.4'
RPM specfile: enable lvm plugin on RHEL7
Merge branch 'collectd-5.3' into collectd-5.4
Conflicts:
contrib/redhat/collectd.spec
Conflicts:
contrib/redhat/collectd.spec
Merge remote-tracking branch 'github/master'
processes plugin: Limit the buffer size used for command line matching.
ARG_MAX is quite big on many systems, for example >100 kByte on
GNU/Linux. This is a problem for systems with tight memory constraints,
for example embedded devices.
This patch uses at most 4 kByte for this, which out to be enough for the
vast majority of users. Users with specific requirements can compile
with "CMDLINE_BUFFER_SIZE=${LOTS}" in their CPPFLAGS to override this
default.
Fixes: #652
ARG_MAX is quite big on many systems, for example >100 kByte on
GNU/Linux. This is a problem for systems with tight memory constraints,
for example embedded devices.
This patch uses at most 4 kByte for this, which out to be enough for the
vast majority of users. Users with specific requirements can compile
with "CMDLINE_BUFFER_SIZE=${LOTS}" in their CPPFLAGS to override this
default.
Fixes: #652