tagomoris / fluent-plugin-route

This is copy of frsyuki's out_route
Apache License 2.0
20 stars 6 forks source link

No such file or directory - addr #3

Open ploef opened 8 years ago

ploef commented 8 years ago

Hi,

I'm using td-agent version 0.12.19 and getting an error using the route plugin:

2016-01-06 21:53:56 +0000 [info]: fluent/agent.rb:125:add_match: adding match pattern="wur-monitor.**" type="route"
2016-01-06 21:53:56 +0000 [trace]: fluent/plugin.rb:118:register_impl: registered output plugin 'route'
2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:364:rescue in main_process: unexpected error error="No such file or directory - addr"
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/uuidtools-2.1.5/lib/uuidtools.rb:587:in ``'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/uuidtools-2.1.5/lib/uuidtools.rb:587:in `ifconfig'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/uuidtools-2.1.5/lib/uuidtools.rb:634:in `mac_address'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/uuidtools-2.1.5/lib/uuidtools.rb:242:in `block in timestamp_create'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/uuidtools-2.1.5/lib/uuidtools.rb:232:in `synchronize'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/uuidtools-2.1.5/lib/uuidtools.rb:232:in `timestamp_create'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:34:in `uuid_timestamp'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:69:in `block (2 levels) in configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:38:in `call'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:38:in `block in replace'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:38:in `each'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:38:in `reduce'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:38:in `replace'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:93:in `check_element'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-mixin-config-placeholders-0.3.0/lib/fluent/mixin/config_placeholders.rb:103:in `configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluent-plugin-route-0.1.3/lib/fluent/plugin/out_route.rb:101:in `configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/agent.rb:129:in `add_match'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/agent.rb:60:in `block in configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/agent.rb:54:in `each'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/agent.rb:54:in `configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/root_agent.rb:82:in `configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/engine.rb:117:in `configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/engine.rb:91:in `run_configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:515:in `run_configure'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:146:in `block in start'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:352:in `call'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:352:in `main_process'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:325:in `block in supervise'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:324:in `fork'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:324:in `supervise'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/supervisor.rb:142:in `start'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/lib/fluent/command/fluentd.rb:171:in `<top (required)>'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/site_ruby/2.1.0/rubygems/core_ext/kernel_require.rb:55:in `require'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/lib/ruby/gems/2.1.0/gems/fluentd-0.12.19/bin/fluentd:6:in `<top (required)>'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/bin/fluentd:23:in `load'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /opt/td-agent/embedded/bin/fluentd:23:in `<top (required)>'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /usr/sbin/td-agent:7:in `load'
  2016-01-06 21:53:56 +0000 [error]: fluent/supervisor.rb:324:fork: /usr/sbin/td-agent:7:in `<main>'
2016-01-06 21:53:56 +0000 [info]: fluent/supervisor.rb:340:supervise: process finished code=256
2016-01-06 21:53:56 +0000 [warn]: fluent/supervisor.rb:343:supervise: process died within 1 second. exit.

If I remove this part from the configuration everything is starting ok.

<match monitor.**>
  type route
  <route **>
    add_tag_prefix clean
    copy
  </route>
  <route **>
    add_tag_prefix esb.messages
    copy
  </route>
</match>

Do you have any idea what is going wrong here?

Regards, Peter

tagomoris commented 8 years ago

It seems came from dependencies, and looks same with this problem: https://github.com/sporkmonger/uuidtools/pull/39

What environment are you using?

geerlingguy commented 6 years ago

Running apt-get install -y net-tools in my Docker build fixed this; ifconfig isn't present on the Debian Stretch image I used as my base (though it was on Debian Jessie), so I had to add that to my Dockerfile while building.