New Question
 
 
PRTG Network Monitor

Intuitive to Use.
Easy to manage.

200.000 administrators have chosen PRTG to monitor their network. Find out how you can reduce cost, increase QoS and ease planning, as well.

Free PRTG
Download >>

 

What is this?

This knowledgebase contains questions and answers about PRTG Network Monitor and network monitoring in general. You are invited to get involved by asking and answering questions!

Learn more

 

Top Tags


View all Tags


Why does my HTTP XML/REST Value sensor return a 404 error?

Votes:

0

Your Vote:

Up

Down

I set up an HTTP XML/REST Value sensor to monitor a REST/JSON value. When the sensor runs, it returns the following error: Protocol Error: The remote server returned an error. (404) Not Found. The error code is code: PE023.

I tested the URL of the probe system in a browser and it works fine. It requires authentication, but I have set this up as well. The URL has the following format: http://www.example.com:55672/api/queues/%2F/mydata_plus This works fine on the system that the probe is running on, but it does not work through PRTG. Is there something in the URL that causes this issue?

404 dotnet error-messages http-sensor http-xml pe023 prtg special-characters url

Created on Jan 22, 2013 4:04:53 PM by  Gerald Schoch [Paessler Support]

Last change on May 6, 2019 11:11:43 AM by  Maike Behnsen [Paessler Support]



1 Reply

Accepted Answer

Votes:

0

Your Vote:

Up

Down

This article applies to PRTG Network Monitor 19 or later

Fixing 404 Errors of the HTTP XML/REST Value Sensor

The HTTP XML/REST Value sensor returns an error when the URL contains specific URL encoded characters. In the case of the question above, the character sequence %2F is the reason for this issue. Sometimes the XML/REST Value sensor (based on .NET) encodes such a sequence again—which results in a broken URL.

Solution

The solution for this issue is to create a new configuration file. This file will force the PRTG .NET XmlValue.exe file to interpret special characters correctly. In this case, this means that this character is not escaped again and the URL is kept encoded.

PRTG runs the XmlValue.exe file with every scan. If a corresponding configuration file is available, the instructions in this file will be considered while running XmlValue.exe. Thus, we can use a configuration file to fix this problem.

Steps to Go

  1. Open a new text editor.
  2. Copy the following text into the editor:

    <?xml version="1.0"?> <configuration> <startup> <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/> </startup> <uri> <schemeSettings> <clear/> <add name="http" genericUriParserOptions="DontUnescapePathDotsAndSlashes"/> </schemeSettings> </uri> </configuration>
  3. Save the text file under the file name XmlValue.exe.config.
  4. Save this file to the Sensor System subfolder of the PRTG program directory. Now PRTG is able to grab the correct value.

Created on Jan 22, 2013 4:11:23 PM by  Gerald Schoch [Paessler Support]

Last change on May 21, 2019 5:14:46 AM by  Maike Behnsen [Paessler Support]



Please log in or register to enter your reply.


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.