What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general.

Learn more

PRTG Network Monitor

Intuitive to Use. Easy to manage.
More than 500,000 users rely on Paessler PRTG every day. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free Download

Top Tags


View all Tags

Custom lookup range

Votes:

0

I have created a custom lookup with the range type. When I try to load the new lookup file, I get an error message ('''' is not a valid integer value).

If I define the range type with a single value instead of a from-to range, I can import it. But that is pretty useless. <?xml version="1.0" encoding="UTF-8"?> <ValueLookup id="beit.cisco.switch.hsrp.state" desiredValue="6" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd"> <Lookups> <SingleInt state="Ok" value="6"> active </SingleInt> <Range state="Warning" from="2" to="5"> standby </Range> <SingleInt state="Error" value="1"> down </SingleInt> </Lookups> </ValueLookup>

lookups range value

Created on Jul 15, 2013 2:57:51 PM

Last change on Jul 15, 2013 2:57:51 PM



Best Answer

Accepted Answer

Votes:

0

This article applies as of PRTG 22

Working with range-based lookups

This is a standard range-based lookup that is included in PRTG by default for reference. The file is called prtg.standardlookups.snmpprinter.cartridgelevel.ovl:

<?xml version="1.0" encoding="UTF-8"?>
<ValueLookup id="prtg.standardlookups.snmpprinter.cartridgelevel" desiredValue="100" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd">
	<Lookups>
		<Range state="Ok" from="16" to="100">Ok</Range>
		<Range state="Warning" from="6" to="15">Low</Range>
		<Range state="Error" from="0" to="5">Critical</Range>
                <Range state="Ok" from="-1" to="-1">No Restriction</Range>
		<Range state="None" from="-2" to="-1">Unknown</Range>
		<Range state="Ok" from="-3" to="-3">Not Empty</Range>
	</Lookups>
</ValueLookup>

Note: You cannot mix different lookup types. When you work with a range-based lookup file, all entries must be range based. You can easily enter a single number by creating a range that goes from and to the same value, for example:

<Range state="Warning" from="6" to="6">Number Six</Range>

More

Created on Sep 7, 2016 7:05:43 AM by  Luciano Lingnau [Paessler]

Last change on Jan 3, 2023 9:32:30 AM by  Brandy Greger [Paessler Support]



4 Replies

Votes:

0

Hello,

thank you very much for your KB-Post. May I ask, which exact version of PRTG are you running? I ask this, because version 13.3.4 (released on July 8th 2013) contains a fix:

Bugfix [Sensors]: PRTG did not accept lookup files containing ranges or bitfields.

Please also be aware, that "You can use only one kind of lookup type in one lookup file. For example, only SingleInts , BitField , or Ranges . Different lookup types in one file are not allowed" (See: PRTG Manual: Define Lookups).

There's also an example available below:

best regards.

Created on Jul 16, 2013 11:40:09 AM by  Torsten Lindner [Paessler Support]

Last change on Sep 7, 2016 7:08:27 AM by  Luciano Lingnau [Paessler]



Votes:

0

Hello Torsten,

Both points you mentioned match in our case. We are using Version 13.2.3 and I missed the information in the manual about using different types in one lookup.

So I changed the lookup file and patched the system and now it works correctly.

Thanks for your help.

best regards Thomas

Created on Jul 16, 2013 12:11:06 PM



Votes:

0

Thomas, thank you for the follow up, and for using PRTG! Have a great week!

Created on Jul 16, 2013 2:26:48 PM by  Torsten Lindner [Paessler Support]



Accepted Answer

Votes:

0

This article applies as of PRTG 22

Working with range-based lookups

This is a standard range-based lookup that is included in PRTG by default for reference. The file is called prtg.standardlookups.snmpprinter.cartridgelevel.ovl:

<?xml version="1.0" encoding="UTF-8"?>
<ValueLookup id="prtg.standardlookups.snmpprinter.cartridgelevel" desiredValue="100" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="PaeValueLookup.xsd">
	<Lookups>
		<Range state="Ok" from="16" to="100">Ok</Range>
		<Range state="Warning" from="6" to="15">Low</Range>
		<Range state="Error" from="0" to="5">Critical</Range>
                <Range state="Ok" from="-1" to="-1">No Restriction</Range>
		<Range state="None" from="-2" to="-1">Unknown</Range>
		<Range state="Ok" from="-3" to="-3">Not Empty</Range>
	</Lookups>
</ValueLookup>

Note: You cannot mix different lookup types. When you work with a range-based lookup file, all entries must be range based. You can easily enter a single number by creating a range that goes from and to the same value, for example:

<Range state="Warning" from="6" to="6">Number Six</Range>

More

Created on Sep 7, 2016 7:05:43 AM by  Luciano Lingnau [Paessler]

Last change on Jan 3, 2023 9:32:30 AM by  Brandy Greger [Paessler Support]




Disclaimer: The information in the Paessler Knowledge Base comes without warranty of any kind. Use at your own risk. Before applying any instructions please exercise proper system administrator housekeeping. You must make sure that a proper backup of all your data is available.