NetXMS Support Forum

English Support => General Support => Topic started by: Borgso on June 14, 2016, 09:02:23 AM

Title: Agent Cache
Post by: Borgso on June 14, 2016, 09:02:23 AM
Im running a proxy/source-node against multiply nodes that have a webpage to display values/statues (Inhouse applications/systems)

Each system is added to netxms as individual node, using a external DCI call on proxynode.
This is a python script that download webpage and parse out the values for each DCI.
There is a cache for this so node that i want more then 1 value from same page does not download it for each DCI as long age of cached download isnt more than X-time, making it goes faster on +2nd poll.

When AgentCache is off, this will slow down DCI poll because of serial(?) polling to the node used as proxy?
Turning on AgentCache the proxynode is going bananas on load and some DCI's get overpopulated with records every minute even if interval is 5min
Looking at Agent log, i can see its polling that many times..

It looks like Agent just spawns threads to it breaks.. Is there a config for MaxPollThread on agent?
And are there any
Title: Re: Agent Cache
Post by: Victor Kirhenshtein on June 14, 2016, 10:01:39 AM
Hi,

currently max number of threads is hard-coded (64). I can make it configurable. Still it looks like a bug that agent do not keep polling interval. Can you please provide agent's log on debug level 7 along with content of dc_config table from agent's local database?

Best regards,
Victor
Title: Re: Agent Cache
Post by: Borgso on June 14, 2016, 10:53:33 AM
Hi thanks for fast reply

Turned debug level 7 on and restartet, proxynode is not having problem with load right after restart so i will wait tomorrow before i send you log+sqlite file.
Title: Re: Agent Cache
Post by: Borgso on June 16, 2016, 11:31:18 PM
PM'ed you log+db
Title: Re: Agent Cache
Post by: Victor Kirhenshtein on June 21, 2016, 09:25:57 PM
Hi,

I see that there are 7340 parameters configured for collection. Strange enough some seems to be duplicates, because there are only 6966 distinct names - but all have different DCI IDs. Is it really that much DCIs on this node? Most of them seems to be external parameters. How long this script executes? Because if there are enough long-running scripts it can overload data collection thread pool and possibly cause other strange effects. I will try to simulate collection of that many external parameters and see if I will be able to reproduce strange behavior you observed.

Best regards,
Victor
Title: Re: Agent Cache
Post by: Borgso on June 22, 2016, 01:12:41 PM
Yes, we are using this node to poll external against nodes that have in-house web-app presenting a simple webpage that proxynode parses to get out the value we want for each DCI.

I have monitored the log from proxynode script, and can see it starts with around 0.1-0.5 sec time used but when agent starts polling more and more nodes at same time this time used are around 4-5sec..

If there have been a agentcache max poll thread this could been fixed?..
Title: Re: Agent Cache
Post by: Tatjana Dubrovica on July 05, 2016, 06:04:53 PM
For now it's not possible. Bug created: https://dev.raden.solutions/issues/1252
Title: Re: Agent Cache
Post by: Victor Kirhenshtein on July 07, 2016, 11:05:23 AM
Implemented in 2.1-M1 (agent will be compatible with 2.0.5 server).

Best regards,
Victor