Geneos action or command is usually calling a binary or script. If you notice the action or command completes with the message cancelled execution of command and call to clear command but no pending command info found this means a command was triggered but the original threshold for the trigger has been cleared before the command has completed execution.
Below is a snippet from a gateway log file. An action called emailtest has been triggered because a threshold has been breached. The action comprises of a command called Test. The command then calls a script alertscripttest.sh which runs on the gateway server.
2023-04-20 09:36:56.218+0100 INFO: ActionManager Action DataItem 'emailtest' generated (variable=/geneos/gateway[(@name="OERH_RMDS_02")]/directory/probe[(@name="Trades")]/managedEntity[(@name="Swansea")]/sampler[(@name="TradesSpecific")][(@type="")]/dataview[(@name="TradesSpecific")]/rows/row[(@name="ARZ")]/cell[(@column="Volume")])
2023-04-20 09:36:56.218+0100 INFO: ActionManager Firing action 'emailtest'
2023-04-20 09:36:56.219+0100 INFO: ActionManager Executing command Test [5]
2023-04-20 09:36:56.219+0100 INFO: CommandManager Executing command [Test] with id [23] for request id [5]
2023-04-20 09:36:56.220+0100 INFO: CommandManager Executing command 'Test' on DataItem '/geneos/gateway[(@name="OERH_RMDS_02")]/directory/probe[(@name="Trades")]/managedEntity[(@name="Swansea")]/sampler[(@name="TradesSpecific")][(@type="")]/dataview[(@name="TradesSpecific")]/rows/row[(@name="ARZ")]/cell[(@column="Volume")]', issued on ''
2023-04-20 09:36:56.220+0100 INFO: CommandManager Received 1 arguments for command
2023-04-20 09:36:56.220+0100 INFO: CommandManager Arg 1: defn[static] type[string] value[/disk2/Gateway/OERH_RMDS_02/gateway/alertscripttest.sh]
Whilst the alertscripttest.sh is running the original threshold condition that was breached has now cleared. As a result the gateway reports the command as cancelled. It is however important to note that the script alertscripttest.sh runs to completion as indicated by the Finished execution message.
2023-04-20 09:37:26.162+0100 INFO: CommandManager cancelling commandId=23, requestId=5
2023-04-20 09:37:26.162+0100 INFO: ActionManager Cancelled execution of command [23] for action AlertEmail456.
2023-04-20 09:37:26.162+0100 INFO: ActionManager Action DataItem 'emailtest' removed (variable=/geneos/gateway[(@name="OERH_RMDS_02")]/directory/probe[(@name="Trades")]/managedEntity[(@name="Swansea")]/sampler[(@name="TradesSpecific")][(@type="")]/dataview[(@name="TradesSpecific")]/rows/row[(@name="ARZ")]/cell[(@column="Volume")])
2023-04-20 09:38:37.012+0100 WARN: CommandManager Internal error: Call to clear command (command id 23) but no pending command info found.
2023-04-20 09:38:37.012+0100 INFO: ActionManager Finished execution of command [23] for action AlertEmail456.
This can be a common occurrence if a command or script takes more than a few seconds to run, this can mean that the original condition that was met is likely to be cleared. The messages can seem confusing that the command is cancelled but it is important to note that any script that is initiated should be run to completion.
Comments
0 comments
Please sign in to leave a comment.