Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/vba/14.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
<img src="//i.stack.imgur.com/RUiNP.png" height="16" width="18" alt="" class="sponsor tag img">elasticsearch Logstash作为服务运行时不向弹性搜索发送数据_<img Src="//i.stack.imgur.com/RUiNP.png" Height="16" Width="18" Alt="" Class="sponsor Tag Img">elasticsearch_Logstash - Fatal编程技术网 elasticsearch Logstash作为服务运行时不向弹性搜索发送数据,elasticsearch,logstash,elasticsearch,Logstash" /> elasticsearch Logstash作为服务运行时不向弹性搜索发送数据,elasticsearch,logstash,elasticsearch,Logstash" />

elasticsearch Logstash作为服务运行时不向弹性搜索发送数据

elasticsearch Logstash作为服务运行时不向弹性搜索发送数据,elasticsearch,logstash,elasticsearch,Logstash,这是存储在/etc/logstash/conf的配置文件 input { file{ path => ["PATH_OF_FILE"] } } output { elasticsearch { host => "172.29.86.35" index => "new" } } 这是我的elasticsearch.yaml文件内容,用于网络和http \# Set the bind address specifically (IPv4 or IPv6): \#network

这是存储在/etc/logstash/conf的配置文件

input
{
file{
path => ["PATH_OF_FILE"]
}
}

output
{
elasticsearch
{
host => "172.29.86.35"
index => "new"
}
}
这是我的elasticsearch.yaml文件内容,用于网络和http

\# Set the bind address specifically (IPv4 or IPv6):

\#network.bind_host: 172.29.86.35

\# Set the address other nodes will use to communicate with this node. If not
\# set, it is automatically derived. It must point to an actual IP address.
\#network.publish_host: 192.168.0.1

\# Set both 'bind_host' and 'publish_host':
network.host: 172.29.86.35

\# Set a custom port for the node to node communication (9300 by default):
\#transport.tcp.port: 9300

\# Enable compression for all communication between nodes (disabled by default):

\#transport.tcp.compress: true

\# Set a custom port to listen for HTTP traffic:
\#http.port: 9200
我正在运行elasticsearch和logstash as service。问题是,当我启动log stash as service时,它不会向elasticsearch发送任何数据。但是,如果我在logstash conf文件中使用相同的配置,并从CLI运行logstash,它就可以正常工作。甚至日志也没有显示任何错误

我正在运行的ES版本是1.4.3,LS版本是1.4.2。
系统环境是RHEL 7

我也遇到了同样的问题。。。 当我使用-f选项执行命令时,它正常工作,但当我启动服务时,不会发生任何事情,/etc/log stash下的日志文件从未更新

作为临时的反措施,我所做的是执行下面的命令(使用&option)


这样,即使我从服务器注销,它也能工作。

您的“#”前面并没有反斜杠,是吗?这可能是权限问题,即用户Logstash运行时没有对日志的读取权限。也许会有帮助。嗨,马格纳斯,不,现实中没有反斜杠。Bdw我尝试将权限设置为777,但我面临同样的问题。不要使文件世界可写。在任何情况下,日志都不得超过775。如果使用
--verbose
选项启用详细日志,日志存储日志会说什么?
Logstash if conffile.conf &