matanox
matanox

Reputation: 13686

how to make filebeat pick up project-specific configuration file

I have the following yml file, in a project directory not the global file beat configuration directory:

filebeat:
  idle_timeout: 5s
  prospectors:
    paths:
      - "data-log/*"

output:
  elasticsearch:
    hosts: ["localhost:9200"]

Running filebeat -configtest produces no output. Running filebeat produces no output either.

I would like the running filebeat daemon to dynamically pick up the configuration from this directory, assuming that the command filebeat should do that. I know this can be set up in the global config file, but I would rather perfrom this dynamically.

What am I doing wrong or what assumptions implied here are false?

Upvotes: 0

Views: 307

Answers (1)

user3175468
user3175468

Reputation: 11

try to strace filebeat process with strace -fp {pid} -s 1024, the lines you should be looking for are stat({file_name}. This way you will see if filebeat resolves path correctly.

Upvotes: 1

Related Questions