Exiting: Couldn't connect to any of the configured Elasticsearch hosts. Errors: [Error connection to Elasticsearch http://localhost:9600: Failed to parse JSON response: json: cannot unmarshal string into Go struct field .Version of type struct { Number string }]
Logstash logs
Hello People , please help to to solve this problem. i have error in Start filebeat in logstash logs.
2019-01-08 16:52:37.678120778 +0530 IST m=+39.155193105 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 16:52:37.678486371 +0530 IST m=+39.155558670 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
Exiting: Couldn't connect to any of the configured Elasticsearch hosts. Errors: [Error connection to Elasticsearch http://localhost:9600: Failed to parse JSON response: json: cannot unmarshal string into Go struct field .Version of type struct { Number string }]
when i change 9600 to 9200 in elasticsearch then i get this output..
system@system-VirtualBox:~/filebeat-6.5.4-darwin-x86_64$ filebeat setup
2019-01-08 17:09:47.667809815 +0530 IST m=+0.166213346 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.6682287 +0530 IST m=+0.166632209 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.669199025 +0530 IST m=+0.167602647 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.669454456 +0530 IST m=+0.167857940 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.669594992 +0530 IST m=+0.167998501 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.672454902 +0530 IST m=+0.170858409 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.673344964 +0530 IST m=+0.171748487 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:47.673409843 +0530 IST m=+0.171813325 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:50.675224024 +0530 IST m=+3.173627583 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:50.678035523 +0530 IST m=+3.176439082 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:50.698629063 +0530 IST m=+3.197032595 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:50.702569341 +0530 IST m=+3.200972865 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:51.121498893 +0530 IST m=+3.619902420 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:51.494875002 +0530 IST m=+3.993278428 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
Loaded index template
Loading dashboards (Kibana must be running and reachable)
2019-01-08 17:09:51.495161457 +0530 IST m=+3.993564881 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:51.496297035 +0530 IST m=+3.994700467 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:51.496405724 +0530 IST m=+3.994809155 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:51.496496642 +0530 IST m=+3.994900074 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
2019-01-08 17:09:51.496570736 +0530 IST m=+3.994974158 write error: failed to open new file: open /var/log/filebeat/filebeat: permission denied
Exiting: fail to create the Kibana loader: Error creating Kibana client: Error creating Kibana client: fail to get the Kibana version: HTTP GET request to /api/status fails: fail to execute the HTTP GET request: Get http://[localhost:5601]:5601/api/status: lookup localhost:5601: no such host. Response: .
open /var/log/filebeat/filebeat: permission denied: You need to run this with sudo on Ubuntu — otherwise the file permissions are wrong as you can see in this error message.
To fix the file permission errors you need to run sudo filebeat setup instead of just filebeat setup.
Is Kibana running on localhost? fail to execute the HTTP GET request: Get http://[localhost:5601]:5601/api/status: lookup localhost:5601: no such host. is probably the next thing you will need to fix.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.