I checked Logstash and it worked fine when it was reading files in local directory. I also ran telnet command:
# telnet localhost 5044
Trying ::1...
Connected to localhost.
Escape character is '^]'.
Connection closed by foreign host.
And it's unclear for me if Logstash works as expected or not. Or it's Beats problem. Any ideas?
I tried to forward logs from Beats to Elasticsearch and it worked good.
Providing filebeat.yml file
I just copied /usr/share/logstash/certs/logstash-forwarder.crt to another server with Filebeat to directory /etc/pki/tls/certs/
The issue is in certificates. Is this correct command to generate them? openssl req -x509 -nodes -newkey rsa:2048 -keyout logstash-forwarder.key -out logstash-forwarder.crt
And this is from lgos:
ERR Connecting error publishing events (retrying): x509: certificate is valid for "ABC", not "myhost"
Sounds like the certificate being used on the Logstash server is not valid for the hostname you're running filebeat on. Maybe you want to add an alternative via -subj?
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.