Commit graph

46 commits

Author SHA1 Message Date
M. van Brummelen
9c6336e5b6
docs: fix manual page groff warning
The only thing the change does is the way the manpage gets parsed, and fixes
follwing warning.

"W: dhcpd-pools: groff-message an.tmac:<standard input>:147: warning: tbl
preprocessor failed, or it or soelim was not run; table(s) likely not
rendered (TE macro called with TW register undefined)
[usr/share/man/man1/dhcpd-pools.1.gz:1]"

Reference: https://www.mail-archive.com/debian-devel@lists.debian.org/msg377263.html
Signed-off-by: M. van Brummelen <mvb@debian.org>
Reviewed-by: Sami Kerola <kerolasa@iki.fi>
2024-08-09 11:00:02 +01:00
Sami Kerola
b96c6c14d2
misc: fix spelling issues
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2019-09-12 22:29:44 +01:00
Sami Kerola
e6e90b4d62
release: 3.0
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-15 13:29:46 +00:00
Sami Kerola
3369278fc0
output: make --skip to take arguments what will be skipped
Accidental typo in usage() caused realisation making skipping to fully
controllable is good idea.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-13 20:23:12 +00:00
Sami Kerola
e4f7259cf6
samples: add prometheus text file collector mustach template
Because prometheus needs timestamp information add that to mustach, and
update manual page what tags are available.

Reference: https://prometheus.io/docs/instrumenting/exposition_formats/
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-13 14:18:05 +00:00
Sami Kerola
eabaa8adc2
thanks: add Troy D. Hanson to credits about uthash
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-13 11:53:21 +00:00
Sami Kerola
c029c7581a
output: make warning and critical colors work in html output
Users should combine this with --color=always to web pages to work
correctly.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-12 22:19:09 +00:00
Sami Kerola
39e6e65201
docs: add mustach sample files
Include samples to installation, and give a hint to user where it can be
found in manual page.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-09 19:49:17 +00:00
Sami Kerola
7d9a5b5561
output: add mustach templating support
Based on José Bollo's mustache C implementation.  This adaptation uses
project specific data structures to avoid overhead with json parsing.

Reference: https://gitlab.com/jobol/mustach.git
Commit: d84608a69033d38c81b8fcff0cb272e225dd5428
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-09 19:49:13 +00:00
Sami Kerola
c55c823753
output: add --skip-ok option
Omit ranges and shared networks that do not exceed warning or critical
thresholds.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-06 22:11:47 +00:00
Sami Kerola
344ed2900d
output: add color support to text output
When --warning or --critical thresholds are defined with text output lines
that exceed threshold will be either yellow (warning) or red (critical).

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-11-06 21:31:57 +00:00
Sami Kerola
782f63c3ad
add --ip-version option to force either IPv4 or IPv6 analysis
Proposed-by: Jeff Balley <jeffrey.bailey@bt.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-09-09 10:28:27 +01:00
Boris Lytochkin
b9cff0d814
introduce -A arg: treat single subnets as shared-network with CIDR as their name
Current output makes some false-positives for situations when multiple
ranges are specified inside single network, for example:

subnet 10.0.0.0 netmask 255.255.254.0 {
	...
	range 10.0.0.1 10.0.0.254;
	range 10.0.1.1 10.0.1.253;
	...
}

An alert for range 10.0.0.1 - 10.0.0.254 will be raised even in situations
when range 10.0.1.1 - 10.0.1.253 is completely empty.  To cope with this
issue, an -A option is added to treat all single networks as shared-network.
This option changes output for both range and shared networks output if
specified.  Frankly saying, using network CIDR as network name is much more
sane for me than 'All Networks'.

Signed-off-by: Boris Lytochkin <lytboris@yandex-team.ru>
2017-07-15 17:26:15 +01:00
Sami Kerola
ae2edb0fbc
man: remove old html table only option argument from manual
Incomplete html page, that was just a html table, was removed some time ago
but deprecated option arguments were unfortunately left to manual that are
now removed.

Reference: 1299737d76
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-01-07 11:01:22 +00:00
Sami Kerola
5eae1b41a7
man: improve synopsis and output limit
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2017-01-06 23:36:36 +00:00
Sami Kerola
a6b77ab785
docs: fix couple typos and improve a sentence in README
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2016-10-02 21:35:29 +01:00
Manuel Hachtkemper
32e2d399a0
alarming: add additional performance data
Options -p or --perfdata (in alarming mode) now enable the output of
additional performance data, i.e.  used, touched and backup addresses per
subnet.

Signed-off-by: Manuel Hachtkemper <hacman@math.uni-bonn.de>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2016-03-31 22:34:27 +01:00
Sami Kerola
0369340710
remove upper limit of sort order definitions
Unlikely to be needed by anyone, but because arbitrary limits are from code
style point of view ugly.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2015-11-30 00:50:18 +00:00
Sami Kerola
1299737d76
make html output to use Bootstrap and DataTables
This make the table output good looking, and allows users to click table
headings to sort data by column without rerunning the analysis.
Unfortunately this change is breaking change, meaning the old CSS tags are
no longer supported, nor partial html output that printed only the table.

Proposed-by: Aaron Paetznick <aaronp@critd.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2015-11-28 20:37:23 +00:00
Sami Kerola
5cede1ff31
add --warn-count and --crit-count options to suppress alarm noise
Alarm criteria based solely on percentage was found to be difficult to be
tricky to setup in environments that has small ranges and big shared-nets
mixed up together.  These two new options should help making alarming more
useful.

Requested-by: Frank Bulk <fbulk@mypremieronline.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2015-11-28 00:33:12 +00:00
Sami Kerola
7f3d553c7f
add --snet-alarms option to suppress excess range alarms
Some users may not want to have alarms about ranges that are part of a
shared-network, so allow them to suppress such.

Requested-by: Frank Bulk <fbulk@mypremieronline.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2015-11-27 23:42:23 +00:00
Sami Kerola
2528c4c9d6
make binary exec path dynamic in scripts referring to it
Everything should just work out of the box without poking.  This change
makes that goal to be yet agian one step closer.  In same go make all
autotools related variable substitutions better.

Requested-by: Martijn van Brummelen <martijn@brumit.nl>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2015-11-25 21:53:29 +00:00
Sami Kerola
d8aef85d01 man: fix character class change
Debian package lint found going back to roman mode was broken.

Reported-by: Martijn van Brummelen <martijn@brumit.nl>
Signed-off-by: Sami Kerola <kerolasa@cloudflare.com>
2015-09-05 13:15:19 +01:00
Sami Kerola
6b88e8d872 man: add tip analysis of include files can be useful
Reported-by: Fredrik Lysén <fredrik.lysen@uadm.uu.se>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-11-08 20:50:26 +00:00
Sami Kerola
3944e289c8 docs: add an example how to use limits with alarming
Proposed-by: Dan Pritts <danno@umich.edu>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-07-12 19:59:50 +01:00
Sami Kerola
28f1e8c54c output: allow user to ignore small ranges and shared networks
Some have configuration which combines small ranges such as one host, and
greater address ranges that are important to monitor.  Especially the one
host ranges tend to cause a lot of false-positive alarms, as they are
immediately 100% full when a machine requests an address.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-07-12 19:29:44 +01:00
Sami Kerola
4becf97fb3 docs: inform how the limits affect to printing when alarming is in use
Proposed-by: Dan Pritts <danno@umich.edu>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-07-11 20:47:09 +01:00
Sami Kerola
30238e9d1c build-sys: use non-recursive build
For reasons see excellent paper 'Recursive Make Considered Harmful' by
Peter Miller.

References: http://miller.emu.id.au/pmiller/books/rmch/
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-04-24 22:46:04 +01:00
Sami Kerola
327b601ea4 docs: fix spelling mistakes in manual page
Also quote dashes used in EXAMPLEs section.

Reported-by: Helmut Grohne <h.grohne@cygnusnetworks.de>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-04-09 21:04:23 +01:00
Sami Kerola
34f73dbae1 docs: thanks to Cheer Xiao this software has IPv6 support
The prof. Xing Li in Tsinghua University, with LI Zimu, asked Cheer to
make the dhcpd-pools more usable for them which I, as a project
maintainer, could not be more pleased.  Whils making the IPv6 analysis to
work Cheer also fixed various other issues.  Kudos to him, and big thanks
to everyone.

CC: Xing Li <xing@cernet.edu.cn>
CC: LI Zimu <lzm@cernet.edu.cn>
CC: Cheer Xiao <xiaqqaix@gmail.com>
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2013-01-15 17:41:38 +00:00
Gilles Bouthenot
a302bc6829 output: add json format support
Reviewed-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Gilles Bouthenot <gilles.bouthenot@univ-fcomte.fr>
2012-12-04 21:30:09 +00:00
Sami Kerola
7685d08cf0 man: fix errors in alarm warning and critical options text
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-11-25 18:23:38 +00:00
Sami Kerola
9df90042e2 build-sys: make alarm warning & critical default configurable
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-11-25 18:03:19 +00:00
Sami Kerola
c48a8d411f man: use configured dhcpd.conf and dhcpd.leases paths
Making dhcpd.conf and dhcpd.leases file references being dynamic causes
manual contents being replaced at compile time, so make some other data
items dynamic as well.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-11-25 18:03:13 +00:00
Sami Kerola
83e12457bc docs: fix spelling mistakes
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-11-20 21:09:53 +00:00
Sami Kerola
b5e518cd5e docs: clarify man page
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-10-09 22:01:49 +01:00
Sami Kerola
a05d793378 docs: add note how to limit alarming scope
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-06-24 16:51:33 +02:00
Sami Kerola
dd5bc03f12 docs: add examples to manual page
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-06-24 16:41:22 +02:00
Sami Kerola
42dd80aeac alarming: make native nagios support to dhcpd-pools
This commit makes integrating the command with nagios much easier.

$ dhcpd-pools -c dhcpd.conf -l dhcpd.leases --critical 80 --warning 75
CRITICAL: dhcpd-pools: Ranges; crit: 14 warn: 22 ok: 220 Shared nets; crit: 1 warn: 0 ok: 4

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2012-06-24 16:40:25 +02:00
Sami Kerola
235825b084 docs: enhance manual page readability
This patch adds consistant underlining to arguments, and unifies
spacing. Also the wording for -L is made much better, it's been
common to hear the manual was unclear about that option.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-09-18 00:34:23 +02:00
Sami Kerola
648891d8bd docs: remove version from manual page
Command version number in manual page output prone to be forgot
at the release time, so it is best to remove it completely.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-07-08 23:10:15 +02:00
Sami Kerola
a31fd0d97a licensing: use FreeBSD license (was GNUv3)
This change will also remove getopt source code and headers,
which has GNU license that I cannot change.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-06-21 22:54:03 +02:00
Sami Kerola
4c9f177b2e docs: add missing full-html flag
Missing both from help output & manual page.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-06-07 22:47:02 +02:00
Sami Kerola
2cb7369e20 docs: help screen & man page
The help screen has now same notation as most of the GNU/Linux
utilities, e.g. if a option requires argument it is marked as
option=ARG. That enabled me to use help2man to make small nroff
fixes to manual page to unify it's outlook as well.

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-06-07 22:02:57 +02:00
Sami Kerola
4593ebd534 Rest of the automake file deletions.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-01-21 19:32:18 +01:00
Sami Kerola
74aef1c34e Import from release candidate 2.13.
Signed-off-by: Sami Kerola <kerolasa@iki.fi>
2011-01-21 18:15:50 +01:00