# Curl: (7) couldn't connect to host

**URL:** <https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709>\
**Category:** Elasticsearch\
**Created:** [January 2, 2019, 8:05pm UTC](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709 "2019-01-02T20:05:27Z")\
**Posts on this page:** 4\
**Page:** 3

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [January 8, 2019, 4:09pm UTC](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709/41 "2019-01-08T16:09:18Z")

</div>

The main problem seems to be that you have a line break in one of your comments:

```auto
# ----------------------------------------------------------- SSL X-Pack
Configuration---------------------------------------------------------------

```

This means that the second line starts with `Configuration`, which is not valid config and is not preceded by a `#`. If you remove the newline between `SSL X-Pack` and `Configuration` so they end up on a single line I think you should be fine. Note that you have this happen in two places.

---

<div class="post-metadata">

**Author:** ![richcollier](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/richcollier/32/115035_2.png) [@richcollier](https://discuss.elastic.co/u/richcollier)\
**Post date:** [January 8, 2019, 4:10pm UTC](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709/42 "2019-01-08T16:10:56Z")

</div>

Which is what I said back here 5 days ago: [Curl: (7) couldn't connect to host](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709/23?u=richcollier)

```auto
in 'reader', line 120, column 1:
Configuration------------------- ...
^

```

There should be no line in the file that begins with `Configuration-------` (like your 120th line of your file). All lines that have section headers have the `#` character at the beginning of the line so that the rest of the line is commented out.

---

<div class="post-metadata">

**Author:** ![simpsonr](https://avatars.discourse-cdn.com/v4/letter/s/ecd19e/32.png) [@simpsonr](https://discuss.elastic.co/u/simpsonr)\
**Post date:** [January 8, 2019, 4:13pm UTC](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709/43 "2019-01-08T16:13:41Z")

</div>

ok, thanks. I will modify.

Rob

---

<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:** [February 5, 2019, 4:18pm UTC](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709/44 "2019-02-05T16:18:13Z")

</div>

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

[Previous page](https://discuss.elastic.co/t/curl-7-couldnt-connect-to-host/162709.md?page=2)
