Custom Notifications

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
dbv
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Custom Notifications

dbv
Hi,

I'm trying to create a simple pushbullet notification when a node comes down. It simply doesn't work. Due to the lack of useful documentation I need your help

The notified.log is logging
Failed to enter notification into database, exiting this notification
org.postgresql.util.PSQLException: Das ResultSet ist nicht richtig positioniert. Eventuell muss 'next' aufgerufen werden.
(resultset can't be positioned. Maybe next has to be called)

I've created simple python script (pushme), which is executable and runs perfectly when called vom from command line.

my notification path is:

<path name="pushme" initial-delay="0m">
        <target interval="0m">
            <name>admin</name>
            <command>pushme</command>
        </target>
</path>

notificationCommands:
    <command binary="true">
                <name>pushme</name>
                <execute>/usr/bin/pushme</execute>
                <comment>pushbullet test</comment>
                <argument streamed="false">
                        <switch>-d</switch>
                </argument>
   </command>

At the moment no argument is needed. No Idea if needed at this state


notifications.xml

    <notification name="pushbullet" status="on">
        <uei>uei.opennms.org/nodes/nodeDown</uei>
        <rule>(IPADDR != '0.0.0.0')</rule>
        <destinationPath>pushme</destinationPath>
        <text-message>All services are down.</text-message>
        <subject>test</subject>
    </notification>

BR
Vincent





Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Custom Notifications

David Hustace

> On Mar 7, 2017, at 3:34 AM, dbv <[hidden email]> wrote:
>
> The notified.log is logging
> Failed to enter notification into database, exiting this notification
> org.postgresql.util.PSQLException: Das ResultSet ist nicht richtig
> positioniert. Eventuell muss 'next' aufgerufen werden.
> (resultset can't be positioned. Maybe next has to be called)

Please provided the entire stack trace.  Thanks.

:David



David Hustace
The OpenNMS Group, Inc.
+1 919 533 0160 x7734


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
Loading...