Telegraf agent - resource consumption

Hi all,
I have this profound question ever since I’ve been using telegraf agent. I know the agent uses small memory and doesn’t affect too much of CPU, but was just wondering.

Can anyone provide any statistics to show what the impact to running telegraf agent would be? I.e. – will there be additional resources that are needed for each server that is running the agent?

Hey @howardyoo,

The amount of resources that Telegraf will consume will be based in part on what kind of workload you are running. The amount of data you’re gathering, how you’re processing it, how many endpoints you’ll need to send it to, will all play a part.

If you’re interested in finding out more about your own Telegraf process, you could try out the procstat input plugin. It will gather metrics about a specific process, such as CPU or memory usage. That will give you a better idea of the resources needed for your specific workload.

Hi @noahcrowley, thanks! I think it’s a good idea to get the stat of my own telegraf process and start from there. Will definitely try it out and post my findings here soon! Procstat input plugin seems very interesting!

Hi howard,

Based on my test, telegraf uses less then 1% of cpu core and not much memory for metric data capture, but requires much cpu and memory for log data capture depending on the log generation speed. (about 30% of cpu core for 20,000 msg/s with tail plugin)

I think that metric_batch_size and metric_buffer_limit configuration affects use of resources but appropriate configuration might be different for each case.