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

Trigger input/output (analog) on a Axis p8221 (for instance)

Votes:

0

Is it possible, based on a certain sensor treshold or state (down/up) to trigger an output on any, but for instance above mentioned device?

We need to trigger several inputs (non IP) so we want to connect a IP based output unit (several outputs) so we can trigger those.

Any idea on how to configure this? And how to only trigger a specific output?

axis input output prtg

Created on Jul 8, 2015 7:09:45 PM



Best Answer

Accepted Answer

Votes:

7

Well, scratch that! They do have that information and they shared it with me.

I have it all working now, i can trigger the output and turn it off after a predefined amount of time using a single URL.

So let me share it here:

In order to open an output contact (nr 1):

http://uname:password@mydeviceIP/axis-cgi/io/port.cgi?action=1:/

In order to close an output contact (nr 1):

http://uname:password@mydeviceIP/axis-cgi/io/port.cgi?action=1:\

In order to open and close (2 seconds) a contact (nr 1):

http://uname:password@mydeviceIP/axis-cgi/io/port.cgi?action=1:/2000\

The url for opening a contact without username and password:

http://mydeviceIP/axis-cgi/io/port.cgi?action=1:/

Created on Jul 24, 2015 11:51:00 AM



10 Replies

Votes:

0

Hi,
we have not tested this so I cannot guarantee if this will work but you might have a look at the EXE Notifications. Those can be used to trigger a script on a certain sensor state, so if you are able to access the device using a script you might give this a try.
best regards

Created on Jul 9, 2015 1:42:25 PM by  Konstantin Wolff [Paessler Support]



Votes:

0

I'm going to contact Axis if their unit (P8221) supports it, or what it supports else...

Get back here after that.

Created on Jul 9, 2015 6:10:13 PM



Votes:

0

They Say it is possible using a "HTTP" request, is that possible with PRTG?

Other thing that popped my mind is: can PRTG send SNMP traps maybe?

Created on Jul 10, 2015 1:58:34 PM



Votes:

0

Hi there,

You can create Notifications and choose

  • Execute HTTP Action
  • Send SNMP Trap

Afterwards, you can add a state trigger to the device or sensor to send the HTTP request or SNMP Trap.

Best regards

Created on Jul 14, 2015 11:19:41 AM by  Felix Saure [Paessler Support]



Votes:

0

Hi,

I figured out to do a http trigger on the device and the Output did indeed get triggered.

However when i try it from PRTG nothing happens.

In the log of the device we get a "unauthorized" message, could make sense that i need to add the user credentials for the I/O unit in PRTG, been searching but i can't figure out where!

I need to create around 60 http sensors with the unique strings to trigger all the Outputs on several devices.

Thank you and kind regars.

Created on Jul 23, 2015 10:17:46 AM



Votes:

0

Hi,

You can add Postdata to the HTTP POST in the settings of the notifications. If this is not accepted by the target device, you will need to create a custom script which is triggered by the notification. You can create a notification with Execute Program.

Best regards

Created on Jul 23, 2015 12:57:14 PM by  Felix Saure [Paessler Support]



Votes:

0

Yes i saw that, but i don't have any clue to know "how" to put the credentials in there.

I have a running case with Axis, but it was very difficult to get the string for triggering the output via http, i doubt if i ever get the info like this......

Do you have any experience with that, like some "common practise"?

Created on Jul 23, 2015 3:13:47 PM



Votes:

0

Hi,

I'm afraid that we do not have these devices in our test environment and it depends on the API of the Axis device, so I cannot assist you in this case, sorry.

In PRTG, the credentials are simply appended to the URL:

/api/getsensordetails.xml?id=sensorid&username=name&password=pass

Best regards

Created on Jul 24, 2015 8:25:45 AM by  Felix Saure [Paessler Support]



Accepted Answer

Votes:

7

Well, scratch that! They do have that information and they shared it with me.

I have it all working now, i can trigger the output and turn it off after a predefined amount of time using a single URL.

So let me share it here:

In order to open an output contact (nr 1):

http://uname:password@mydeviceIP/axis-cgi/io/port.cgi?action=1:/

In order to close an output contact (nr 1):

http://uname:password@mydeviceIP/axis-cgi/io/port.cgi?action=1:\

In order to open and close (2 seconds) a contact (nr 1):

http://uname:password@mydeviceIP/axis-cgi/io/port.cgi?action=1:/2000\

The url for opening a contact without username and password:

http://mydeviceIP/axis-cgi/io/port.cgi?action=1:/

Created on Jul 24, 2015 11:51:00 AM



Votes:

0

Thanks for sharing the solution with the community! Good to hear that it's working now.

Created on Jul 24, 2015 12:11:09 PM by  Felix Saure [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.