Can't get ElasticSearch bundled with Bitbucket 5.0.0 up and running

SSL configuration.

Elastic Search configured to listen to https://localhost:7992/

Bitbucket and ssh, both, work properly.

Anyone facing similar issue?


Log output:

2017-05-10 14:56:50,999 INFO  [I/O dispatcher 33]  c.a.b.s.s.t.DefaultElasticsearchConnectionTester Testing connection with Elasticsearch failed due to exception org.apache.http.ConnectionClosedException: Connection closed

2017-05-10 14:56:50,999 DEBUG [I/O dispatcher 33]  c.a.b.s.s.t.DefaultElasticsearchConnectionTester Detailed Exception: 

java.util.concurrent.CompletionException: org.apache.http.ConnectionClosedException: Connection closed

at java.util.concurrent.CompletableFuture.encodeThrowable(

at java.util.concurrent.CompletableFuture.completeThrowable(

at java.util.concurrent.CompletableFuture.uniApply(

at java.util.concurrent.CompletableFuture$UniApply.tryFire(

at java.util.concurrent.CompletableFuture.postComplete(

at java.util.concurrent.CompletableFuture.completeExceptionally(

at com.atlassian.elasticsearch.client.apache.httpclient.ApacheRequestExecutor$1.failed(

at org.apache.http.concurrent.BasicFuture.failed(

at org.apache.http.impl.nio.client.AbstractClientExchangeHandler.failed(

at org.apache.http.nio.protocol.HttpAsyncRequestExecutor.endOfInput(

at org.apache.http.impl.nio.DefaultNHttpClientConnection.consumeInput(

at org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(

at org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(

at org.apache.http.impl.nio.reactor.AbstractIODispatch.inputReady(

at org.apache.http.impl.nio.reactor.BaseIOReactor.readable(

at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(

at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(

at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(

at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(

at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$


Caused by: org.apache.http.ConnectionClosedException: Connection closed

... 12 common frames omitted

1 answer

1 accepted

1 votes
Jeff Thomas Atlassian Team Jun 02, 2017

Have you run through any of the troubleshooting steps available at Troubleshooting steps for Bitbucket Server Code Search?

Just based on the error you're seeing, it would imply that either Elasticsearch is not running or there is a firewall blocking the connection.

If you SSH into the server and run "curl http://localhost:7992", do you get a response?

Thanks! Very useful troubleshooting guide.

At the end, I had to 

- correct my password in, and 

- replace the https with http in


Suggest an answer

Log in or Join to answer
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

638 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot