cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

OneAgent plugin not executing

ewoelkerling
Contributor

Hi!  Just getting into Dynatrace so bit of a newbie question, so apologies up front if this is a silly one 😎 

 

I've built a OneAgent plugin that simply gathers a HOST metric (SysUpTime) and returns it.  It

  • compiles OK (python wise)s
  • passes the simulator fine (shows what I'd expect), executes fine, 'sends' metrics
  • build and deploy are OK
  • upload to the Dynatrace server as a custom plugin is ok
  • Global monitoring settings show it as active, even added a host level override to make 'sure' it's assigned so to speak

Once it was all set up, I monitored the log files on the agent and

  • it sees the plugin and there are no specific errors etc that are being shown - but it never seems to execute. 
  • There are no clashes etc that it notes

 

It seems like I'm missing something super-obvious here, but I just can't put my finger on it.  Any advice on where to proceed from here to try to understand why it is no executing? 

 

plugin.json & .py file attached. 

 

All help/suggestions are greatly appreciated! 

3 REPLIES 3

Mike_L
Dynatrace Guru
Dynatrace Guru

Hi,

 

Try to remove:
"technologies": ["PYTHON"],

 

And instead add:

"processTypes": [0],

 

Mike

Mike

Hi Mike, 

 

  Thanks for the info - it seems to have worked, although I'm still getting weird behavior (well.. unexpected on my part anyway 😀 ).

 

Looking at the plugin logs agent side I now see entries like the below, and in the GUI I can see one host (my test host) associated and 'monitoring correctly': 

 

2022-10-02 23:12:21.403 UTC [00000428] info [native] 1064(MainThread) - [do] Plugin loop status: time_taken: 0.0, engines_info: ['<PluginEngine, meta_name:custom.python.test.sysuptime_plugin '
'id:0x1b0146b9ca0>, executions:17 ',
'<PluginEngine, meta_name:ruxit.perfmon.dotnetV4 id:0x1b0146b9760>, '
'executions:17 ',
'<PluginEngine, meta_name:dynatrace.python.ntp id:0x1b0147efe80>, '
'executions:0 ',
'<PluginEngine, meta_name:dynatrace.python.heartbeat id:0x1b014924340>, '
'executions:17 '],

 

Strangely though, it doesn't seem to be sending the data through - I can't see it in the metrics explorer (although I can see the entry for the metric with no data), and same for API query.   I've given it about 30 minutes since it started running correctly and no dice. 

 

  Anything you can see that might be stopping that part? 

 

Thanks for the help! 

 

Thoughts? 

Oops..  scratch the second comment (no data)..  I appear to have had an attack of stoopid and somehow removed the code to actually send the data..  added that back in and everything's now fine..  Thanks Mike - very much appreciated! 

 

Featured Posts