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

Setting limits for sensor in bulk or via API

Votes:

0

Hi,

Is there some way I can setup limits for the sensor CPU or for a sensor with an certain tag? Can this be done in the lookup-files?

we are using 1600+ sensors, all from the default templates from PRTG, but non of them have set limits. Selecting all sensors of a certain type and then change the channel-settings won't work all the time.

hope that there is an easy-er way

limits prtg sensors

Created on Jan 7, 2016 8:16:15 AM

Last change on May 1, 2018 10:44:56 AM by  Luciano Lingnau [Paessler]



Best Answer

Accepted Answer

Votes:

1

Dear jfigueredo

The PRTG API allows the definition of channel limits. The API call to set the upper limit to 25, for example, looks like this.

/api/setobjectproperty.htm?id=2123&subtype=channel&subid=0&name=limitmaxerror&value=25

Note: You have to set limits using this API call before you can enable limits for the channel.

Once you have set limits, you can enable the limits using the following API call:

/api/setobjectproperty.htm?id=2123&subtype=channel&subid=0&name=limitmode&value=1

For more information, see section Object Manipulation in the manual.

Created on Feb 12, 2016 12:33:14 PM by  Arne Seifert [Paessler Support]

Last change on Sep 6, 2018 10:22:27 AM by  Brandy Greger [Paessler Support]



20 Replies

Votes:

0

I am sorry, multi-edit is the only way to change limits in bulk.

The PRTG API is also not very useful for this, because channel limits are not accessible through the API.

In principle, you could stop the PRTG core service and edit the "PRTG Configuration.dat", which is an XML file. That file is located in "C:\ProgramData\Paessler\PRTG Network Monitor". The channel limits in the configuration file are multiplied by 125. This is a side effect of PRTG's internal data handling. However, it is easy to damage the file when edited. We also provide no technical support for this, you do it completely at your own risk.

Created on Jan 7, 2016 5:43:41 PM by  Arne Seifert [Paessler Support]



Votes:

0

Can I use the API at least to request the channel limits values, Not to modify them?

Created on Feb 11, 2016 8:21:44 PM



Accepted Answer

Votes:

1

Dear jfigueredo

The PRTG API allows the definition of channel limits. The API call to set the upper limit to 25, for example, looks like this.

/api/setobjectproperty.htm?id=2123&subtype=channel&subid=0&name=limitmaxerror&value=25

Note: You have to set limits using this API call before you can enable limits for the channel.

Once you have set limits, you can enable the limits using the following API call:

/api/setobjectproperty.htm?id=2123&subtype=channel&subid=0&name=limitmode&value=1

For more information, see section Object Manipulation in the manual.

Created on Feb 12, 2016 12:33:14 PM by  Arne Seifert [Paessler Support]

Last change on Sep 6, 2018 10:22:27 AM by  Brandy Greger [Paessler Support]



Votes:

0

Hi, this looks very promising!

But when I use

/api/setobjectproperty.htm?id=11574&subtype=channel&subid=0&name=limitmaxerror&value=25

It displayes 'OK', but I do not see the '25' in the upper error limit when I go to the 'Edit channel' of that sensor. (it was set to 1 before using the above command and it is still 1) I go there by clicking the Messages 'Edit channel settings' Gear symbol in the bottom right corner. It is a sensor of type Windows MSMQ Queue Length.

And I realy would like the option to read the current values of limitmaxerror and limitmode, but when I use the lines below I get 'Property not found'.

/api/getobjectproperty.htm?id=11574&subtype=channel&subid=0&name=limitmaxerror
/api/getobjectproperty.htm?id=11574&subtype=channel&subid=0&name=limitmode

Is the API for getobjectproperty of these channel settings not available yet? Or do I make a mistake somewhere? For me it is not very clear where to find the name of the property that I want to have the information about, is there a guide for that, or a list somewhere in the knowledgebase?

Created on Apr 12, 2016 12:44:47 PM

Last change on Jan 4, 2017 12:49:16 PM by  Luciano Lingnau [Paessler]



Votes:

0

Dear ACDuindam

Which PRTG version are you using? The API call you use should work. The possible names are

  • limitmaxerror
  • limitmaxwarning
  • limitminwarning
  • limitminerror

It is not possible to read the limit values via the API. Currently it is not planned to implement it. The only way to read these values is to access the configuration directly ("PRTG Configuration.dat", found in "C:\ProgramData\Paessler\PRTG Network Monitor".)

Created on Apr 12, 2016 1:34:24 PM by  Arne Seifert [Paessler Support]



Votes:

0

The statusbar at the bottom of the screen shows: PRTG Network Monitor 16.1.22.2658, I think that's the problem! I think I have to wait until we also use a later version!

It would be great if the API getobjectproperty for just reading the these limits would be available in a new version too! We want to use it to check the sensors on their configuration, and get a list of those that are not configured well. Based on this limitmaxerror a notification should be sent. If it is not configured OK, the notification will not be sent at all, and problems are solved later than needed! Since we have many sensors, it is not possible to check them 1 by 1, and sensors added lateron can be wrong again too.

Thanks for your quick reply!

Created on Apr 12, 2016 2:22:51 PM



Votes:

0

Dear ACDuindam

The API call to set limits should be available with the current 16.2.23 version.

About reading limit settings, please don't expect anything soon.

Created on Apr 13, 2016 9:26:12 AM by  Arne Seifert [Paessler Support]



Votes:

0

Hi, I just found this thread and upgraded my installation to 12.2.23.3270 and I can confirm the setting of limits is working well for me here, both Min and Max, so thank you very much for adding this feature!

Created on Apr 20, 2016 2:39:48 PM



Votes:

0

Hi, how to clear a limit? Omitting parameter value doesn't have an effect and value=0 or value=-1 sets these limits ... Thanks in advance!

Created on Feb 2, 2017 9:37:12 AM



Votes:

0

Hi Chris,

In the upcoming version "17.x.30" you will be able to clear the limit fields via the API. An example API-Call would be:

/api/setobjectproperty.htm?id=ID&subtype=channel&subid=SUBID&name=PROPERTY&value=

So basically just leave the "value" parameter empty and the field will be cleared.

Best regards.

Created on Mar 2, 2017 8:45:23 AM by  Dariusz Gorka [Paessler Support]



Votes:

0

I also would like to edit global channels settings. Especially for CPU. Any update on this feature?

Created on Jul 17, 2017 2:53:31 PM



Votes:

0

Hi Seth,

Unfortunately, there are no news at the moment regarding this topic. Please check the release notes from time to time for more information.

Best regards

Created on Jul 18, 2017 9:16:40 AM by  Dariusz Gorka [Paessler Support]



Votes:

1

PTF ChannelLimits is an application that allows you to get an overview of and alter the channel limits of your sensors.

Using the filter options, you can get an overview of threshold limits from specific sensors ie all your CPU sensors

More info here

Created on Jul 19, 2017 2:21:52 PM



Votes:

1

Hello, In trying to set limits for some of my sensors via the API, I'm able to set the limitmaxwarning and limitmaxerror properties per channel, but I'm unable to set limitmode to 1. I have verified that if limitmode is set to 1, via the web UI, i can set it back to 0 via the API.

It doesn't seem to matter if the max/min limits are set before or after trying to set limitmode = 1, as doing either way does not work.

This seems like a bug.

API call is: https://<server>/api/setobjectproperty.htm?id=28323&subtype=channel&subid=10&name=limitmode&value=1&username=<username>&passhash=<hash>

I'm on version 18.3.42.1748

Created on Aug 10, 2018 2:39:06 PM



Votes:

0

Hi there,

This seems to be a bug, you are right. I have opened an internal development ticket to fix this issue in one of the coming new stable versions.

Best regards.

Created on Aug 13, 2018 1:17:59 PM by  Dariusz Gorka [Paessler Support]



Votes:

0

Hi there,

Just got the information that the fix is already ready and will be released with Version 18.x.43 in the coming weeks.

Best regards.

Created on Aug 14, 2018 12:21:00 PM by  Dariusz Gorka [Paessler Support]



Votes:

0

Update:

We've released version 18.3.43.2317 on AUGUST 14TH 2018 - It is now available and includes the fix. Please try it out if you're having issues with this. For the complete release notes, please refer to:

Best Regards,
Luciano Lingnau [Paessler Support]

Created on Aug 15, 2018 4:51:08 AM by  Luciano Lingnau [Paessler]



Votes:

0

I can confirm that the fix is working, Thanks!

Created on Aug 17, 2018 5:04:57 PM



Votes:

0

Hi, Is there a way to add same limit to multiple channels? I have to monitor some mailboxes witch will have the same limits, there are over 100 channels on multiple sensors that need the same error limit.

Created on Sep 8, 2020 2:35:25 PM



Votes:

0

Hello, I'm afraid it's not possible to edit multiple channels at once, you can however edit multiple sensors at once using the Multi Edit.

Created on Sep 9, 2020 6:51:35 AM by  Timo Dambach [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.