# Issues when enabling TLS on Logstash

**URL:** <https://discuss.elastic.co/t/issues-when-enabling-tls-on-logstash/75566>\
**Category:** Logstash\
**Created:** [February 17, 2017, 10:08pm UTC](https://discuss.elastic.co/t/issues-when-enabling-tls-on-logstash/75566 "2017-02-17T22:08:27Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![prodrg](https://avatars.discourse-cdn.com/v4/letter/p/3bc359/32.png) [@prodrg](https://discuss.elastic.co/u/prodrg)\
**Post date:** [February 17, 2017, 10:08pm UTC](https://discuss.elastic.co/t/issues-when-enabling-tls-on-logstash/75566/1 "2017-02-17T22:08:27Z")

</div>

Greetings,

I am configuring the stack to work on TLS/SSL. I configured SSL on both ES and Kibana and it works fine. Now, when I try to configure Logstash, I cannot get it to connect to ES. The following error appears:

`[ERROR][logstash.outputs.elasticsearch] Attempted to send a bulk request to elasticsearch, but no there are no living connections in the connection pool. Perhaps Elasticsearch is unreachable or down? {:error_message=>"No Available connections", :class=>"LogStash::Outputs::ElasticSearch::HttpClient::Pool::NoConnectionAvailableError", :will_retry_in_seconds=>64}`

My `conf.d` file looks like this:

```
 elasticsearch {
        user => " *****"
        password => " ******"
        ssl => true
        cacert => "/path/to/ca.crt"
        ...
    }

```

And this is my `logstash.yml`

```
xpack.monitoring.elasticsearch.url: "https://<hostname>:9200"
xpack.monitoring.elasticsearch.password: " ******"
xpack.monitoring.elasticsearch.username: ******

```

Any idea of what's going on?

Regards

---

<div class="post-metadata">

**Author:** ![prodrg](https://avatars.discourse-cdn.com/v4/letter/p/3bc359/32.png) [@prodrg](https://discuss.elastic.co/u/prodrg)\
**Post date:** [February 20, 2017, 4:24pm UTC](https://discuss.elastic.co/t/issues-when-enabling-tls-on-logstash/75566/2 "2017-02-20T16:24:22Z")

</div>

Found the solution.

Needed to add the certificate authority generated by certgen to my keystore (this isn't documented on [Logstash and Security](https://www.elastic.co/guide/en/x-pack/current/logstash.html#ls-http-auth-pki), so I had to guide myself with the error message from a ClientProtocolException and googling). Even disabling `ssl_certificate_validation` didn't work.

---

<div class="post-metadata">

**Author:** ![weltenwort](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/weltenwort/32/53885_2.png) [@weltenwort](https://discuss.elastic.co/u/weltenwort)\
**Post date:** [February 20, 2017, 8:09pm UTC](https://discuss.elastic.co/t/issues-when-enabling-tls-on-logstash/75566/3 "2017-02-20T20:09:43Z")

</div>

Thank you for sharing your solution with the community, @prodrg!

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [March 20, 2017, 8:09pm UTC](https://discuss.elastic.co/t/issues-when-enabling-tls-on-logstash/75566/4 "2017-03-20T20:09:58Z")

</div>

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