fluentd-docker-image icon indicating copy to clipboard operation
fluentd-docker-image copied to clipboard

rewrite_tag_filter plugin not found

Open DavidHe1127 opened this issue 4 years ago • 3 comments

Try to run fluentd container with a sample config file but receive error below when starting up the container:

2021-01-22 21:20:28 +0000 [error]: config error file="/fluentd/etc/fluentd.conf" error_class=Fluent::ConfigError error="Unknown output plugin 'rewrite_tag_filter'. Run 'gem search -rd fluent-plugin' to find plugins"

Environment

fluent/fluentd:v1.6-debian-1

Config

<source>
  @type http
  port 8080
  bind 0.0.0.0
</source>

<filter *.*>
  @type record_transformer
  enable_ruby
  <record>
    something ${record["message"]["foo"]}
    remove_keys ${record["message"]["baz"]}
  </record>
</filter>

<match *.*>
  @type rewrite_tag_filter
  <rule>
    key message
    pattern /^\[(\w+)\]/
    tag $1.${tag}
  </rule>
</match>

Any idea?

DavidHe1127 avatar Jan 22 '21 21:01 DavidHe1127

This is because fluent-plugin-rewrite-tag-filter is not contained this image.

If you want to build your own image, please refer to the section: https://github.com/fluent/fluentd-docker-image#how-to-build-your-own-image

cosmo0920 avatar Mar 12 '21 07:03 cosmo0920

And when following the instructions to build a custom image doesn't work, then what?

I created a custom image, And I see:

# gem list

...
fluent-config-regexp-type (1.0.0)
fluent-plugin-rewrite-tag-filter (2.4.0)   <---- There's my plugin
fluentd (1.16.2)
...

I get:

config error file="/fluentd/etc/fluent.conf" error_class=Fluent::NotFoundPluginError error="Unknown filter plugin 'rewrite_tag_filter'. Run 'gem search -rd fluent-plugin' to find plugins"

daveseff avatar Feb 14 '24 05:02 daveseff

Same problem

CarlosFdez77 avatar Mar 04 '24 13:03 CarlosFdez77