How to suppress errors in telegraf log



I have a bunch of servers with different roles and I want to monitor mongo metrics on mongodb servers, docker metrics for application servers and so on. However, I don’t want to have different telegraf config files on each server, because it will add complexity to ansible roles and playbooks.

I deployed the same telegraf config on every server and it works, but telegraf log is full of unrelated error messages. Is there a way to fully disable input after some amount of errors? Or maybe a way to discover local services and enable only appropriate inputs?

1 Like

Telegraf doesn’t have a method to do this built in right now, but I think this issue might track what you are interested in: