0

I am monitoring a printer usage via a munin snmp plugin. I configured it by typing

sudo munin-node-configure --shell --snmp myprinter.example.com

which instructed me to create a symlink to

/usr/share/munin/plugins/snmp__print_supplies

The problem is that the printer reports "Waste Toner" (internal name supply1_2) at level -5000 which makes the graph invisible

Now, this shouldn't happen, as the source code of the plugin has this function:

sub wash_data {
    # Get rid of supply-levels reporting negative values
    foreach my $supply (keys (%supplies)) {
        if ($supplies{$supply}{level} < 0) {
            delete $supplies{$supply};
            print "# Deleting entry $supply: supply level unknown.\n" if $Munin::Plugin::SNMP::DEBUG;
        }
    }
}

What can I do to remove this wrong data, or to have "0" as the minimum value at the Y scale?

Magnetic_dud
  • 3,702

1 Answers1

0

Create a copy of /usr/share/munin/plugins/snmp__print_supplies edit in line 100, the line

print "graph_args --base 1000 -l 0 --upper-limit 100  \n";

edit in

print "graph_args --base 1000 -l 0 --upper-limit 100 --lower-limit 0 --rigid \n";
Magnetic_dud
  • 3,702