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


Custom XML sensor does not give error

Votes:

0

Your Vote:

Up

Down

Hi,

I have created a custom sensor that retreives some values via powershell and hand them to PRTG afterwards. The sensor appeared to work just fine until this morning when it had to give an error, which it did not. The value my script returned i way above the error level, but my sensor does not go down. It does not even give me a warning. The added XML is the XML node that is supposed to give me a down status.

    <result>
        <channel>_BIProcessorQueue</channel>
        <unit>Custom</unit>
        <CustomUnit>#</CustomUnit>
        <mode>Absolute</mode>
        <showChart>1</showChart>
        <showTable>1</showTable>
        <float>0</float>
        <value>44664</value>
        <LimitMaxError>499</LimitMaxError>
        <LimitMaxWarning>200</LimitMaxWarning>
        <LimitWarningMsg>This queue has over 200 messages.</LimitWarningMsg>
        <LimitErrorMsg>This queue has over 500 messages.</LimitErrorMsg>
    </result>

custom-sensor exe-xml xml

Created on Nov 27, 2018 1:12:09 PM by  KasperB (0) 1

Last change on Nov 27, 2018 4:13:46 PM by  Birk Guttmann [Paessler Support]



1 Reply

Accepted Answer

Votes:

2

Your Vote:

Up

Down

From what I see your XML seems to be okay - but I admit I had to add <PRTG> tags and remove quite some spaces from what you posted.. but I don't think that necessarily is the issue.

<PRTG>
	<result>
		<channel>_BIProcessorQueue</channel>
		<unit>Custom</unit>
		<CustomUnit>#</CustomUnit>
		<mode>Absolute</mode>
		<showChart>1</showChart>
		<showTable>1</showTable>
		<float>0</float>
		<value>44664</value>
		<LimitMaxError>499</LimitMaxError>
		<LimitMaxWarning>200</LimitMaxWarning>
		<LimitWarningMsg>This queue has over 200 messages.</LimitWarningMsg>
		<LimitErrorMsg>This queue has over 500 messages.</LimitErrorMsg>
	</result>
</PRTG>

What I am missing is this tag:

<LimitMode>1</LimitMode>

You did a great job mentioning all those settings in the output - but this one is missing - and cause it is 0 by default, your limits aren't active and therefor the sensor will not raise an error.

Details can be found here: https://www.paessler.com/manuals/prtg/custom_sensors

Test it out while forcing the script to return higher counts and you will see once you set the LIMITMODE it fill cause alerts in PRTG.

If it doesn't help, please reply!

Regards

Florian Rossmark

www.it-admins.com

Created on Nov 27, 2018 2:52:53 PM by  Florian Rossmark (2,760) 2 2



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.