Some SNMP implementations actively report the interface speed as 0 (e.g., when disconnected). This led the plugin to report both min and max to be 0, which later confuses RRDTool, with errors such as
[ERROR] Unable to create '/var/lib/munin/example.net/192.2.0.1-snmp_if_combined_vlan-37-send-d.rrd': failed to parse data source 600:0:0: min must be less than max in DS definition
when trying to creates the RRDs. Ultimately, this would prevent the graph creation from suceeding with errors such as
[ERROR] In RRD: Error updating /var/lib/munin/example.net/192.2.0.1-snmp_if_combined_vlan-37-send-d.rrd: opening '/var/lib/munin/example.net/192.2.0.1-snmp_if_combined_vlan-37-send-d.rrd': No such file or directory
Signed-off-by: Olivier Mehani <shtrom@ssji.net>
From a summary comment in the code:
If a stacked graph is requested, plot the total. Rather than
aggregating them with CDEFs of SUMs, we sum them in the script, which
allows us to create real series than can be easily borrowed by other
loaning graphs.
Those series are recv_bits and send_bits.
There are longstanding bugs with them (dating back to snmp__if). This
has been documented, as well as some potential ad hoc fixes for the
data.
Some outdated bug were also removed from the doc.
Signed-off-by: Olivier Mehani <shtrom@ssji.net>
The current recommended firmware for EX3400 (JUNOS 15.1X53-D55.5) lists the routing engines as 'Routing engine <member id>' when the switches are stacked in a Virtual Chassis.
The former code failed to detect these strings, so I relaxed it a bit.
This matches the documentation found here: https://kb.juniper.net/InfoCenter/index?page=content&id=KB17526&actp=search
Changes:
- More queries supported (inputpower, batterycurrent, batteryruntime (how long
have we been running on battery), batterypercent (percent remaining),
inputlinebads (how often was input bad))
- fix a few wrong units (e.g. current is measured in amp, not in watt)
- some UPSes violate RFC 1628 by not returning the number of input-/
output-lines they have. In this case assume 3 lines instead of 0
(and just printing nothing at all).
- Make mode parameters all lowercase instead of camelcase - camelcase
just looks retarded in the plugin-symlink-names.
- some more smaller fixes
- Nothing wrong with the plugin, but checkbashisms triggers on the
presence of a variable called $HOSTNAME
- Changing the variable name in the plugin is the "easy way out".