Logstash5.0 插件安装

离线安装

下载插件包:

例如需要下载exec包,在github网站 https://github.com/logstash-plugins/logstash-output-exec 下载 exec包。

logstash-output-exec-master.zip

安装:

将exec包上传到Logstash所在的服务器并解压到目录:/opt/logstash/plugins下

修改Logstash的Gemfile文件,再最后添加一行:gem "logstash-output-exec", :path => "/opt/logstash/plugins"

最后执行安装:bin/logstash-plugin install --no-verify

Installing...

Installation successful

OK......

测试:

省略。。。

在线安装

需要修改为国内的源:

$ vim /opt/logstash-5.1.1/Gemfile

# This is a Logstash generated Gemfile.

# If you modify this file manually all comments and formatting will be lost.

source "https://rubygems.org"

gem "logstash-core", :path => "./logstash-core"

gem "logstash-core-queue-jruby", :path => "./logstash-core-queue-jruby"

gem "logstash-core-event-java", :path => "./logstash-core-event-java"

gem "logstash-core-plugin-api", :path => "./logstash-core-plugin-api"

保存并执行:bin/logstash-plugin install logstash-output-exec

你可能感兴趣的:(Logstash5.0 插件安装)