Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

watch_method = "inotify" doesn't work #5375

Closed
stanislav-zaprudskiy opened this issue Feb 4, 2019 · 2 comments
Closed

watch_method = "inotify" doesn't work #5375

stanislav-zaprudskiy opened this issue Feb 4, 2019 · 2 comments
Labels
area/tail bug unexpected problem or unintended behavior

Comments

@stanislav-zaprudskiy
Copy link

Relevant telegraf.conf:

[[inputs.tail]]
watch_method = "inotify"

System info:

$ cat /etc/*release
LSB_VERSION=base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch
Red Hat Enterprise Linux Server release 6.9 (Santiago)
Red Hat Enterprise Linux Server release 6.9 (Santiago)
$ uname -r
2.6.32-696.1.1.el6.x86_64
$ telegraf --version
Telegraf 1.9.3 (git: HEAD 6ad8c8b0)

Steps to reproduce:

  1. Configure Telegraf's tail plugin with watch_method = "inotify"

Expected behavior:

It should created new metrics on arrival of new lines into the tailed file.

Actual behavior:

It doesn't create new metrics at all for the watched files - like inotify doesn't work.

Additional info:

If I update the config file with watch_method = "poll", and start watching the exact same files and add the exact same lines into the watched files (in other words, what effectively changes is just watch_method), then it works - metrics are being parsed and written to output.

debug = true in agent conf doesn't provide any clue.

I use tail plugin with csv data format and parse Apache HTTPD access log files (csv formatted)

@danielnelson danielnelson added the bug unexpected problem or unintended behavior label Feb 4, 2019
@danielnelson danielnelson self-assigned this Mar 1, 2019
@sgtsquiggs
Copy link
Contributor

Are you sending SIGHUP to Telegraf? There is a known issue #3573 that applies to tail plugin w/ inotify

@danielnelson danielnelson removed their assignment Sep 1, 2021
@sspaink
Copy link
Contributor

sspaink commented Nov 2, 2022

Because #3573 has been resolved, I am assuming this issue can be closed as well seeing there hasn't been new reported issues related to this since. Please comment or reopen if that isn't the case so we can investigate further. Thanks!

@sspaink sspaink closed this as completed Nov 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/tail bug unexpected problem or unintended behavior
Projects
None yet
Development

No branches or pull requests

5 participants