×
Back to ITRS Internal Only FAQ
Internal documentation only
This page has been marked as draft.
[INTERNAL] How to automatically restart a netprobe if it goes down
Note:
- This solution only applies if the netprobes are running on the same server as the gateway
STEP 1
- Run a Gateway-probeData plug-in on your gateway in your setup (refer to the image for an example)
Sample XML Code:
<sampler name="probedata">
<plugin>
<Gateway-probeData></Gateway-probeData>
</plugin>
</sampler>
STEP 2
- Create a command for running a script to start a downed netprobe (refer to the image for an example)
Sample XML Code:
<command name="startnp">
<targets>
<target>/home/aptlorenzo/Downloads/netprobe</target>
</targets>
<userCommand>
<type>script</type>
<runLocation>gateway</runLocation>
<args>
<arg>
<static>./startnp.sh</static>
</arg>
</args>
</userCommand>
</command>
Notes:
- The target option should contain the directory location of the script file you want to run
- The script file should contain the bash script for running your downed netprobe (refer to the image for an example)
Sample Bash Code:
STEP 3
- Create an action for the rule (refer to the image for an example)
Sample XML Code:
<action name="startnp">
<command ref="startnp">
<args></args>
</command>
</action>
Notes:
- Options should be set to “command” and Reference the command you have created in the previous step
STEP 4
- Create a rule that will activate once a netprobe’s connection status is “Down” (refer to the image for an example)
Sample XML Code:
<rule name="startnp">
<targets>
<target>/geneos/gateway[(@name="Demo Gateway")]/directory/probe[(@name="probe")]/managedEntity[(@name="monitoring entity")]/sampler[(@name="probedata")][(@type="")]/dataview[(@name="probedata")]/rows/row[(@name="probe5")]/cell[(@column="connectionState")]</target>
</targets>
<priority>5</priority>
<block>
<if>
<like>
<dataItem>
<property>@value</property>
</dataItem>
<string>Down</string>
</like>
<transaction>
<update>
<property>state/@severity</property>
<severity>critical</severity>
</update>
<action ref="startnp"></action>
</transaction>
<transaction>
<update>
<property>state/@severity</property>
<severity>ok</severity>
</update>
</transaction>
</if>
</block>
</rule>
Note:
- Find the connection status column in the gateway-probedata plug-in (STEP 1) and use it as your target, you can add multiple targets on a single rule.
["Geneos"]
["FAQ"]