我正在尝试启动Docker容器。我正在使用docker-elk.yml文件生成ELK容器。Elasticsearch和Kibana容器运行正常。但是对于Logstash,它正在启动并进入容器bash,但有时它会自动停止。
容器的日志:
[2019-04-11T08:48:26,882] [INFO] [logstash.runner]启动Logstash {“ logstash.version” =>“ 6.6.0”}
[2019-04-11T08:48:33,497] [INFO] [logstash.pipeline]启动管道{:pipeline_id =>“ main”,“ pipeline.workers” => 4,“ pipeline.batch.size” = > 125,“ pipeline.batch.delay” => 50}
[2019-04-11T08:48:34,062] [INFO] [logstash.outputs.elasticsearch] Elasticsearch池URL已更新{:changes => {:removed => [],:added => [{{3} }}}
[2019-04-11T08:48:34,310] [WARN] [logstash.outputs.elasticsearch]恢复了与ES实例{:url =>“ http://elasticsearch:9200/]”}}的连接
[2019-04-11T08:48:34,409] [INFO] [logstash.outputs.elasticsearch] ES输出版本已确定{:es_version => 6}
[2019-04-11T08:48:34,415] [WARN] [logstash.outputs.elasticsearch]检测到6.x及更高版本的群集:
type
事件字段将不会用于确定文档_type {:es_version => 6}[2019-04-11T08:48:34,469] [INFO] [logstash.outputs.elasticsearch]
新的Elasticsearch输出{:class =>“ LogStash :: Outputs :: ElasticSearch”,:hosts => [“ // elasticsearch:9200”]}
[2019-04-11T08:48:34,486] [INFO] [logstash.outputs.elasticsearch]使用来自{:path => nil}的映射模板
[2019-04-11T08:48:34,503] [INFO] [logstash.outputs.elasticsearch]
尝试安装模板{:manage_template => {“ template” =>“ logstash- ”,“ version” => 60001,“ settings” => {“ index.refresh_interval” =>“ 5s”} ,“ mappings” => {“ _ default _” => {“ dynamic_templates” => [{“ message_field” => {“ path_match” =>“ message”,“ match_mapping_type” =>“ string”,“ mapping” => { “ type” =>“ text”,“ norms” => false}}},{“ string_fields” => {“ match” =>“ ”,“ match_mapping_type” =>“ string”,“ mapping” => {“ type” =>“ text”,“ norms” => false,“ fields” => {“ keyword” => {“ type” =>“ keyword”,“ ignore_above” => 256}}}}} }],“属性” => {“ @ timestamp” => {“ type” =>“ date”},“ @ version” => {“ type” =>“关键字”},“ geoip” => {“动态“ => true,”属性“ => {” ip“ => {” type“ =>” ip“},”位置“ => {” type“ =>” geo_point“},”纬度“ => { “ type” =>“ half_float”},“经度” => {“ type” =>“ half_float”}}}}}}}}
[2019-04-11T08:48:34,960] [INFO] [logstash.inputs.beats]敲打输入:启动输入侦听器{:address =>“ 0.0.0.0:5000”}
[2019-04-11T08:48:34,985] [INFO] [logstash.pipeline]管道成功启动{:pipeline_id =>“ main”,:thread =>“#”}
[2019-04-11T08:48:35,077] [INFO] [logstash.agent]管道运行{:count => 1,:running_pipelines => [:main],:non_running_pipelines => []}
[2019-04-11T08:48:35,144] [INFO] [org.logstash.beats.Server]在端口5000上启动服务器
[2019-04-11T08:48:35,499] [INFO] [logstash.agent]成功启动Logstash API端点{:port => 9600}
[2019-04-11T08:48:50,591] [INFO] [logstash.outputs.file]打开文件{:path =>“ / usr / share / logstash / output.log”}
[2019-04-11T13:16:51,947] [WARN] [logstash.runner] SIGTERM已收到。关机。
[2019-04-11T13:16:56,498] [INFO] [logstash.pipeline]管道已终止{:pipeline_id =>“ main”,:thread =>“#”}
它是否尝试要求相对路径?在Ruby 1.9中已将其删除。 uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:59:在'require'中:
似乎您的ruby安装缺少心理功能(用于YAML输出)。 要消除此警告,请安装libyaml并重新安装红宝石。
[ERROR] 2019-04-11 14:18:02.058 [main] Logstash-java.lang.IllegalStateException:Logstash由于错误而停止处理:
(GemspecError)加载logstash-core.gemspec时发生LoadError: 加载错误:心理-java.lang.RuntimeException:错误:我们无法将嵌入式jar复制到temp目录中,因此它需要相对路径吗?在Ruby 1.9中已将其删除。 uri:classloader:/META-INF/jruby.home/lib/ruby/stdlib/rubygems/core_ext/kernel_require.rb:59:在'require'中:
似乎您的ruby安装缺少心理功能(用于YAML输出)。 要消除此警告,请安装libyaml并重新安装红宝石。
[ERROR] 2019-04-11 13:42:01.450 [main]
Logstash-java.lang.IllegalStateException:Logstash由于错误而停止处理:(GemspecError)加载logstash-core.gemspec时出现LoadError:加载错误:psych-java.lang.RuntimeException:BUG:我们可以不能将嵌入式jar复制到临时目录
我试图删除容器中的tmp文件夹。但这不起作用。