snmp monitoring of printers in The Dude

Snmp

There are many instructions on the net on how to install the monitoring server The Dude from Mikrotik. Now the monitoring server package is released only for RouterOS. I used version 4.0 for Windows.

snmp monitoring of printers in The Dude

Here I wanted to consider how to monitor printers on the network: monitor the level of toner, if it is over, display a notification. Launch:

snmp monitoring of printers in The Dude

Click connect:

snmp monitoring of printers in The Dude

Click add device (red plus) and enter the ip address of the printer:

snmp monitoring of printers in The Dude

In the next step, click discovery, it finds all available probes, click finish:

snmp monitoring of printers in The Dude

Double-click on the icon that appears, the settings open, select the type "printer", and click "ok":

snmp monitoring of printers in The Dude

Right click on the icon and select view:

snmp monitoring of printers in The Dude

In the label field, write OIDs:
[Device.Name] – device name
[oid("1.3.6.1.2.1.43.5.1.1.16.1")] – printer model
[oid("1.3.6.1.2.1.43.11.1.1.6.1.1")] – cartridge type
[oid("1.3.6.1.2.1.43.11.1.1.9.1.1")] – toner level
In the image tab, you can attach your icon:

snmp monitoring of printers in The Dude

We leave, it turns out like this:

snmp monitoring of printers in The Dude

Not on all printers, oid("1.3.6.1.2.1.43.11.1.1.9.1.1") immediately shows the toner level, on some this parameter shows how many pages are left to print. To calculate the toner level, you need to divide how many pages are left to print by the total cartridge resource and multiply by 100. To do this, select β€œview” again, then Functions:

snmp monitoring of printers in The Dude

Click create new function (red plus):

snmp monitoring of printers in The Dude

I called the function toner:

snmp monitoring of printers in The Dude

In the code field, write the formula and save:

round(100*oid("1.3.6.1.2.1.43.11.1.1.9.1.1")/oid("1.3.6.1.2.1.43.11.1.1.8.1.1"))

In the label, replace [oid("1.3.6.1.2.1.43.11.1.1.9.1.1")] with the function call [toner()]

snmp monitoring of printers in The Dude

We leave. It turns out like this:

snmp monitoring of printers in The Dude

To find out the necessary oid and set the necessary parameters, you can use the snmp walk function, the right button on the printer - Snmp bypass tools:

snmp monitoring of printers in The Dude

A tree of printer objects is produced:

snmp monitoring of printers in The Dude

We right-click on the one we need and click copy OID.

Notifications

Now let's set up event notifications (the cartridge is over). Open the printer, go to the services tab, press the plus sign (add a new service):

snmp monitoring of printers in The Dude

In the probe field, click three dots to select the desired probe:

snmp monitoring of printers in The Dude

Let's create our own probe, press the red plus:

snmp monitoring of printers in The Dude

I named it toner, select type SNMP, default agent, default Snmp profile,
We prescribe Oid which is responsible for the toner level 1.3.6.1.2.1.43.11.1.1.9.1.1, type Oid Integer, comparison method>= 1

snmp monitoring of printers in The Dude

We save and select the newly created toner in the probe field, in the alerts tab you can configure which alerts we want to receive and save:

snmp monitoring of printers in The Dude

For demonstration, I chose that the toner level should not be lower than 80, the printer turned red:

snmp monitoring of printers in The Dude

snmp monitoring of printers in The Dude

Source: habr.com

Add a comment