使用以下命令 -
logstash.bat -f D:\confignfig.txt --path.settings D:\Software\Elasticsearch\logstash-5.5.0\config\ -l LogstashLogs
但是我收到了这个错误 -
ERROR StatusLogger找不到log4j2配置文件。使用默认值 配置:仅将错误记录到控制台。警告:不能 找到logstash.yml,它通常位于$ LS_HOME / config或 的/ etc / logstash。您可以使用--path.settings指定路径。 继续使用默认值发生意外错误! :error => 坏URI(不是URI?): file:/// D:\ Software \ Elasticsearch \ logstash-5.5.0 \ config“ - LogstashLogs“/log4j2.properties,:backtrace => [“d:/Software/Elasticsearch/logstash-5.5.0/vendor/jruby/lib/ruby/1.9/uri/common.rb:176:在 分裂”, “d:/Software/Elasticsearch/logstash-5.5.0/vendor/jruby/lib/ruby/1.9/uri/common.rb:210:在 解析”, “d:/Software/Elasticsearch/logstash-5.5.0/vendor/jruby/lib/ruby/1.9/uri/common.rb:747:在 解析”, “d:/Software/Elasticsearch/logstash-5.5.0/vendor/jruby/lib/ruby/1.9/uri/common.rb:994:在 URI”, “d:/Software/Elasticsearch/logstash-5.5.0/logstash-core/lib/logstash/logging/logger.rb:77:在 初始化“,”org / jruby / ext / thread / Mutex.java:149:同步'“, “d:/Software/Elasticsearch/logstash-5.5.0/logstash-core/lib/logstash/logging/logger.rb:75:在 初始化”, “d:/Software/Elasticsearch/logstash-5.5.0/logstash-core/lib/logstash/runner.rb:229:在 执行”, “d:/Software/Elasticsearch/logstash-5.5.0/vendor/bundle/jruby/1.9/gems/clamp-0.6.5/lib/clamp/command.rb:67:在 跑”, “d:/Software/Elasticsearch/logstash-5.5.0/logstash-core/lib/logstash/runner.rb:209:在 跑”, “d:/Software/Elasticsearch/logstash-5.5.0/vendor/bundle/jruby/1.9/gems/clamp-0.6.5/lib/clamp/command.rb:132:在 跑”, “d:\ SOFTWARE \ Elasticsearch \ logstash-5.5.0 \ LIB \引导\ environment.rb中:71:在 (根)“]
知道这里发生了什么吗?任何建议将不胜感激。
答案 0 :(得分:0)
这似乎是一个已知问题,预计将在下一个logstash版本5.6.0中修复。
请参阅:https://discuss.elastic.co/t/logstash-5-5-0-error-statuslogger-no-log4j2-configuration-file-found/92921 https://github.com/elastic/logstash/issues/7526
答案 1 :(得分:0)
从根文件夹运行logstash修复此问题。我不知道这是否是已知问题但是如果你从bin文件夹运行logstash你可能会得到'ERROR StatusLogger找不到log4j2配置文件'