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

HTTP XML Sensor: Rain Value not found if it's not raining

Votes:

0

Hi guys, we're setting up Weather Monitoring for several locations, because we have installed several microwave links and just want to know how the weather is at those locations. As I found on PRTG Demo Website, I want to use http://api.openweathermap.org with the "HTTP XML-/REST" sensor, what is working. Unfortunately, the API deletes several values if they are not needed. So if it's not raining in a city, the "rain" node is deleted off XML Values. In those cases the Rain Sensor is in Alterting state, because "Node rain not found in xml result". Has anyone an idea what I can do to prevent this sensor from going into Error State?

Thanks and stay safe!

weather xml xml-rest

Created on Nov 26, 2021 10:21:49 AM



3 Replies

Votes:

0

Hello Tobias,

Thank you for your message.

Regarding the issue you are facing, I'm afraid that the HTTP XML/REST sensor expects that the node "rain" exists and can't be configured to avoid triggering and alert when it doesn't.

To avoid that, I invite you to create a custom script which will check the existence of that node and return a value according to the result you get. If you only want to monitor this information, you can use the script with the EXE/Script sensor (returns a single value), otherwise you need to use the EXE/Script Advanced for multiple data.

In both cases, I invite you to make sure that the script returns a response in the corresponding format as indicated in this manual: https://www.paessler.com/manuals/prtg/custom_sensors.

If you have questions, do not hesitate.

Regards.

Created on Nov 29, 2021 8:46:38 AM by  Florian Lesage [Paessler Support]

Last change on Nov 29, 2021 8:47:16 AM by  Florian Lesage [Paessler Support]



Votes:

0

Hi Florian,

thanks for your reply. I will have a look at this idea later. In the Meantime, used this KB to auto-acknowledge the alert for that specific sensor (https://kb.paessler.com/en/topic/5903-how-to-auto-acknowledge-a-down-sensor-in-prtg). This is working pretty fine and the customer is also fine with the solution.

However, thanks alot for your help! Stay safe, Tobias

Created on Nov 29, 2021 9:40:58 AM



Votes:

0

Thank you very much for the update. If I can be of further assistance, do not hesitate.

Have a nice day.

Created on Nov 29, 2021 9:44:50 AM by  Florian Lesage [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.