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

EXE/SCRIPT Sensor return wrong value



I save the script below as a BAT file in "EXE" folder of probe, and then I setup EXE/SCRIPT sensor. Why it is still return "OK"? Thanks.

IF "2" EQU "2" ( ECHO 2:ERROR EXIT /b 2 ) ELSE ( ECHO 0:OK EXIT /b 0 )

exe script sensor

Created on Aug 9, 2013 10:26:54 AM

2 Replies



please try removing the /b flag from your exit statements and then recreate the sensor for testing.
Now it should exit properly.
Best regards

Created on Aug 12, 2013 5:44:41 AM by  Konstantin Wolff [Paessler Support]



It is okay now. Thank you very much.

Created on Aug 12, 2013 6:29:02 AM

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.