the --test option does not work with tail plugin.
is there any alternative to --test option for tail plugin?
i am not able to read a file from a certain directory using tail where as two other files from the very same directory has no issue. how can i test the conf file for the problematic file?
What are you trying to achieve by using the --test option with tail? The test option is meant to try out all inputs once quickly and exit. Given tail is waiting for output nothing may show up in the time period that test runs.
so basically i have tail on three files which reside in the same directory and have same permissions.
among these two are being written into the influxdb while one of them is not.
all three files are getting updated consistently and tail should work on them alike.
so basically i want to capture what exactly is happening with the problematic file.
that is why i want to use test to see what happens when telegraf tries to read this problematic file.
Have you considered using the
--test-wait function if you need to wait a few seconds for input?
--test-wait wait up to this many seconds for service inputs to complete
in test or once mode. Implies --test if not used with --once.
What I like to do is to instead switch to using the
inputs.file. Sounds like your file is getting written to, so you have example data, then use the file input with the same options and see what Telegraf does when it parses the file as-is.