Hello, we just moved our PRTG server. Because we were running on pretty old PRTG version, we decided to install PRTG on new server and just manually set up our sensors. We have also few probes where we use Advance XML sensors to monitor our Firebird database. On the probes servers we downloaded new probe installer and installed it over the old probes.
After I set up one of our Advaced XML sensors, it immediately shows error PE233. I checked result log of my sensor and it is empty (altought it is 14 KB big). When I run script manually from Powershell, result is OK and I don't use any input parameters.
Do you guys have any advice what should I check? On old version the script works fine.
Article Comments
Hello, thanks for you reply. Result file (located in Logs\sensors) is empty. When I open file in notepad it is 14 lines filled randomly with spaces.
Jun, 2021 - Permalink
Follow up:
script is pretty simple for now :
Write-Host "<?xml version=""1.0"" encoding=""UTF-8"" ?>"
Write-Host "<prtg>"
Write-Host "<error>1</error>"
Write-Host "<text>$($Error[0])</text>"
Write-Host "</prtg>"
Jun, 2021 - Permalink
Hi there,
Thank you for the update.
It seems like that the script is not working correctly. Please run the script in 32bit Powershell to check whether this works in 32bit.
Jul, 2021 - Permalink
Hello, thanks for reply.
I am running the script in Powershell (32bit) and script is working fine (it prints whole XML from my previous example).
Jul, 2021 - Permalink
Hey there,
Please also check whether the script is executed with the same user as you used in the manual test. You can define this in the settings of the sensor.
Jul, 2021 - Permalink
Yes, it should be. Sensor had checked option Use Windows credentials of parent device.
And on Root group I have filled Credentials for Windows Systems with my current user account (the same Im testing script on). Is there any way how to check, the credentials are right? I think it is right, but just for check.
Jul, 2021 - Permalink
Hi there,
you can enable the option "Write Results" in the settings tab of the Sensor. This will create additional logs in the data directory of PRTG: https://helpdesk.paessler.com/en/support/solutions/articles/7600006351163-how-and-where-does-prtg-store-its-data
Jul, 2021 - Permalink
Hello, I have already enabled the option "Write Results", but the log file is empty.
Jul, 2021 - Permalink
If the log file is created but empty, the Sensor is executed but the script does not deliver any result. Another possible option would be that a security software blocks the Probe service to execute the script as a child-process.
Jul, 2021 - Permalink
Thanks for all advice.
At the end, the problem was in the Write-Host
command. I used Write-Output '<prtg>'
instead and script started working again
Jul, 2021 - Permalink
Hi there,
Please let me know whether the correct script output was displayed in the result file from your Sensor? If possible, please add the result here.
Thank you in advance!
Jun, 2021 - Permalink