Logstash not able to connect to elastic search hosted on asw

[2022-12-21T07:09:39,189][INFO ][logstash.runner          ] Log4j configuration path used is: /etc/logstash/log4j2.properties
[2022-12-21T07:09:39,205][INFO ][logstash.runner          ] Starting Logstash {"logstash.version"=>"8.5.3", "jruby.version"=>"jruby (2.6.8) 2022-10-24 537cd1f8bc OpenJDK 64-Bit Server VM 17.0.5$
[2022-12-21T07:09:39,210][INFO ][logstash.runner          ] JVM bootstrap flags: [-Xms1g, -Xmx1g, -Djava.awt.headless=true, -Dfile.encoding=UTF-8, -Djruby.compile.invokedynamic=true, -Djruby.jit.thresh$
[2022-12-21T07:09:42,291][INFO ][logstash.agent           ] Successfully started Logstash API endpoint {:port=>9600, :ssl_enabled=>false}
[2022-12-21T07:09:43,356][INFO ][org.reflections.Reflections] Reflections took 179 ms to scan 1 urls, producing 125 keys and 438 values
$ility => v8` unless explicitly configured otherwise.
[2022-12-21T07:09:44,695][INFO ][logstash.outputs.elasticsearch][main] New Elasticsearch output {:class=>"LogStash::Outputs::ElasticSearch", :hosts=>["https://esuserf$
[2022-12-21T07:09:45,225][INFO ][logstash.outputs.elasticsearch][main] Elasticsearch pool URLs updated {:changes=>{:removed=>[], :added=>[https://user:xxxxxx@eshost$
[2022-12-21T07:09:46,021][ERROR][logstash.javapipeline    ][main] Pipeline error {:pipeline_id=>"main", :exception=>#<LogStash::ConfigurationError: Could not connect to a compatible version of Elastics$
[2022-12-21T07:09:46,027][INFO ][logstash.javapipeline    ][main] Pipeline terminated {"pipeline.id"=>"main"}
[2022-12-21T07:09:46,041][ERROR][logstash.agent           ] Failed to execute action {:id=>:main, :action_type=>LogStash::ConvergeResult::FailedAction, :message=>"Could not execute action: PipelineActi$
[2022-12-21T07:09:46,173][INFO ][logstash.runner          ] Logstash shut down.
[2022-12-21T07:09:46,197][FATAL][org.logstash.Logstash    ] Logstash stopped processing because of an error: (SystemExit) exit
org.jruby.exceptions.SystemExit: (SystemExit) exit
        at org.jruby.RubyKernel.exit(org/jruby/RubyKernel.java:790) ~[jruby.jar:?]
        at org.jruby.RubyKernel.exit(org/jruby/RubyKernel.java:753) ~[jruby.jar:?]
        at usr.share.logstash.lib.bootstrap.environment.<main>(/usr/share/logstash/lib/bootstrap/environment.rb:91) ~[?:?]

My output configuration for logstash
logstash 8.5.3 version
elasticsearch version number" : "7.10.2"

output {
  stdout {
    codec => rubydebug
  elasticsearch {
		hosts => ["https://eshost:443"]
    user => "es-user"
    password => "es-password"
		index => "logstash-%{+YYYY.MM.dd}" 

I believe you are trying to connect to OpenSearch? OpenSearch is different. You can't use Logstash 8.x elasticsearch output to connect to OpenSearch.

OpenSearch/OpenDistro are AWS run products and differ from the original Elasticsearch and Kibana products that Elastic builds and maintains. You may need to contact them directly for further assistance.

(This is an automated response from your friendly Elastic bot. Please report this post if you have any suggestions or concerns :elasticheart: )

i am connecting to Elasticsearch hosted on aws to sync django logs to this particular index

Since you are using Elasticsearch 7.10.2, you should be using Logstash 7.10.x instead of 8.x.

how can i install particular version of logstash could you please help

You can download past releases from https://www.elastic.co/downloads/past-releases#logstash, but you should upgrade your Elasticsearch to the latest 7.17.8 as 7.10 is EOL.

Also if we are using aws opensearch which agent we can use ?

You will need to check with AWS on that.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.