Pandora FMS Community

Data server module: read once /send many

alex · 22 abr 2014, 16:16 · 2 mensajes · 64 visitas

  1. Inicio del debate

    Hi all, as far as I understand (and used so far) each data server module executes and gets the value to be sent to the Pandora server from the command specified in the module_exec statement. So far I'm encountering more and more cases where a single command from the Linux shell returns all I need (I mean dozens of values) and so far I launch the way I did was to do module_begin module_name value1 module_exec commandX | grep value1 ... module_end module_begin module_name value2 module_exec commandX | grep value2 ... module_end and so on. To be more precise I'd like to monitor the most important datasets (40) of our ZFS pool but each query to ZFS pool takes 20-30 seconds regardless if I ask for information of dataset or information for all of them. So if I have to run the query for each dataset (given that I defined the a module for each dataset) it'll take between 600 and 1000 seconds for the 30 of them meaning too much time. Is there a way to collect such information more efficiently? In other words I guess the Pandora agents was written in a way assuming that the value would be returned by the command in no time (or few seconds) but there are cases where the response time is huge. Is there anyone who would like to share their experience with such cases? Also I read that the agent can be scheduled with cron but is highly not recommended. If cron is an option I would think to save in a temporary file the values of the query taking a lot of time and then the module will read from there. How to do that? Many thanks in advance, Alex

Entra en tu cuenta para publicar.