Definition of SNMP Queries

(Last update of this topic: 12-02-2021)

Navigation:  Monitoring and Reporting > SNMP > Custom SNMP Queries >

Definition of SNMP Queries

(Last update of this topic: 12-02-2021)

Previous pageReturn to chapter overviewNext page

The definition of a SNMP query consists of different specifications (see figure steadyPRINT Center - Definition of SNMP query). In the following you will find the respective explanation.

 

sp_center_110

Figure 122: steadyPRINT Center - Definition of SNMP query

 

Name

Enter a name for your SNMP query. The English name is a mandatory field as it is used as default value. The German name is optional and is used when the language setting of is set to German.

 

Category

Select one of the categories (Custom, Printer or Toner) for your SNMP query. Depending on the category you have selected, different functions for the setup of the SNMP query are available.

 

Custom

The category Custom offers the possibility to arrange all further steps individually. The Monitoring tab displays Custom SNMP queries under "Others".

 

Toner

The category Toner enables you to store a color for the toner level. If you create a SNMP query in the category Toner, all default SNMP queries for Toner (grouped by Purchasing) will be overwritten. Usually, toner queries are only requested if the pre-defined SNMP queries do not provide any values or if additional fill levels of other printer components are desired.

 

Printer

SNMP queries of the category Printer are displayed in the tab Controlling.

 

Manufacturer

Select a manufacturer or create a new entry for a manufacturer by clicking .... In order to create a manufacturer, enter the name and press OK.

 

Model

You can select or create a model. To create a model, click .... Enter the name of the model and subsequently select the corresponding manufacturer from the drop-down list. Confirm your entry with OK.

 

OID Query

Having selected category, manufacturer and model, you can now determine the OID queries that are to be evaluated by this SNMP query. Select a OID query from the list and add it with +. Several OIDs can be combined to one expression. Accordingly, you can add several OIDs to one SNMP query. A new OID query can be created by clicking the button ... in the line OID definition opening the window Overview of OID queries.

 

Expression

The value analysis from the OID queries can be determined via the expression. The steadyPRINT Center shows the result in the SNMP view later on. Each OID query receives a number which is marked with # in the table of OID queries with the first entry having the number 0, the second on the number 1 and so on. The validity of each expression is checked and can either result in a binary value ( 1 (true) or 0 (false)), a number or a character string.

 

The following arithmetic operators are supported in numeric expressions.

 

Operator

Description

<

less than (logical operator)

>

greater than (logical operator)

<=

less than or equal (logical operator)

>=

greater than or equal (logical operator)

<>

unequal (logical operator)

=

equal (logical operator)

IN

Comparison of a list of elements (e.g.: Ready,Printing,Warming Up)

LIKE

Comparison of a character sequence. It completely or partly corresponds to the pattern (e.g.: *mode*).

 

Placeholders in form of * or % can be used. They are permitted at the beginning or the end, but not within the search term, e.g. mo*us.

+

Addition of two numeric values (numerical operator).

-

Subtraction of two numeric values (numerical operator).

*

Multiplication of two numeric values (numerical operator).

/

Division of two numerical values (numerical operator).

%

Residual value (Modulo) from a division of two numeric values  (numerical operator).

 

The result of an OID query can be used in the input field by comprising the number of the expression with curly brackets.

 

The expression {0} + {1} would for example add the numbers (#) 0 and 1 to the query results of the OID query and send back the sum as the result of the expression.

 

Example (numeric expression): The query result of the first OID query be the numeric value 5 and the result of the second OID query the numeric value 7. The result of the previously defined calculation be 12, this is 5 + 7 = 12.

 

The expression {0}{1} would bring together the query results of the OID query with the numbers (#) 0 and 1.

Example (character sequence): The query result of the first OID query be the character sequence X738de and the result of the second OID query the sequence Printer. The result by using the expression {0}{1} be a  combination of both character sequences X738deDrucker.

 

Note

SQL Expressions (for Experts)

             

Generally, you can use the entire SQL syntax for the expressions and its evaluations. For more detailed information https://msdn.microsoft.com/de-de/library/system.data.datacolumn.expression(v=vs.80).aspx.

 

Some examples are shown and explained in chapter SNMP: Terms .

 

Unit

At this point you can define the unit for the display of the result of your expression. As a default value, no unit is used. The unit percentage (%) can be selected from the list. In order to generate a custom unit, click the button ... in the line Units in order to open the window for generating units. Enter the name (multilingual) and confirm with OK. Finally, select the just created unit from the list. Which unit is selected has no influence on the calculation of the expression! It merely serves the purpose of understanding and legibility.

 

Evaluation as Warning and Error

Define here when the result of your expression is to produce a warning or an error. The validation of the event consists of an operator and a threshold or one or more reference values. You can select the required logical operator from the list under warning or error.

 

When creating relational expressions the following operators are permitted:

 

Operator

Description

<

less than (logical operator)

>

greater than (logical operator)

<=

less than or equal (logical operator)

>=

greater than or equal (logical operator)

<>

unequal (logical operator)

=

equal (logical operator)

IN

Comparison of a list of elements (e.g.: Ready,Printing,Warming Up)

LIKE

Comparison of a character sequence. It completely or partly corresponds to the pattern (e.g.: *modus*).

 

Placeholders in form of * or % can be used. They are permitted at the beginning or the end, but not within the search term, e.g. mo*us.

 

Validation

In order to validate your expression, unfold the group box Validation. Enter the information necessary for the query of the device:

 

IP: Enter the IP address of the device that you want to query

Port: The SNMP port to query the device. By default, SNMP uses the port 161.

Operation: The command of the SNMP query. Three possible commands are available for selection:

GET: Query of single values.

GET_NEXT: Query of the following value.

GET_BULK: Query of all following values (recursive) depending of the specified OID.

Community String: The community string represents a user ID or a password. Usually, most SNMPv2 devices use the factory-set community string public for reading.

 

 

Note

Use SNMP Version

             

For the query of network components steadyPRINT uses SNMPv2 by default.

 

Result

Click Validate, in order to validate your expression. At first, checks whether the network component is accessible by using the specified connection information. Then, the specified OIDs are checked in order to validate the expression as a whole. The following figures show different scenarios for a results evaluation.

 

sp_center_113

Figure 123: steadyPRINT Center - SNMP query ok

 

sp_center_114

Figure 124: steadyPRINT Center - SNMP query failed (Device inaccessible)

 

Solution: The device cannot be accessed at the specified IP address, the port and/or by using the community string.

 

sp_center_112

Figure 125: steadyPRINT Center - SNMP query failed (incorrect expression)

 

Solution: An evaluation of the queried values by using the specified expression is not possible. In this example, the leading curly bracket in the expression has been forgotten.

 

sp_center_115

Figure 126: steadyPRINT Center - SNMP query failed (OID not found)

 

Solution: At least one OID could not be assigned in the defined expression. In this example, no OID was specified at all. The user forgot to add the selected OID of the query via the button