# Fail to get kibana version: HTTP GET request to http:/localhost:5600/api

**URL:** https://discuss.elastic.co/t/fail-to-get-kibana-version-http-get-request-to-http-localhost-5600-api/182887
**Category:** Beats
**Tags:** filebeat
**Created:** [May 27, 2019, 10:24am UTC](https://discuss.elastic.co/t/fail-to-get-kibana-version-http-get-request-to-http-localhost-5600-api/182887 "2019-05-27T10:24:12Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![faad021](https://avatars.discourse-cdn.com/v4/letter/f/9fc348/32.png) [@faad021](https://discuss.elastic.co/u/faad021)
#### Post date: [May 27, 2019, 10:24am UTC](https://discuss.elastic.co/t/fail-to-get-kibana-version-http-get-request-to-http-localhost-5600-api/182887/1 "2019-05-27T10:24:12Z")

</div>

Hi all,  
I am running elasticsearch and kibana in a container and i am trying to link filebeat to kibana but I am having an error. I am still a noob in this.However, I succesfully had results when i installed them locally but this seems difficult for me to run it in a container. below are my commands and error message that i get when running the last command. Maybe i am doing something wrong here.

```
docker network create -d bridge mynetwork
------------------------------------------------------------------------------------------------------------------------
docker run --network=mynetwork --name elasticsearch -p 9200:9200 -p 9300:9300 -e 
"discovery.type=single-node" docker.elastic.co/elasticsearch/elasticsearch:7.0.1
------------------------------------------------------------------------------------------------------------------------
docker run --network=mynetwork --name kibana -p 5601:5601 --link elasticsearch:elasticsearch  
-e "ELASTICSEARCH_URL=http://elasticsearch:9200" docker.elastic.co/kibana/kibana:7.0.1
-------------------------------------------------------------------------------------------------------------------------
docker run --network=mynetwork --link elasticsearch:elasticsearch --name filebeat 
docker.elastic.co/beats/filebeat:7.0.1 setup -E filebeat.input.paths=/var/jenkins_home -E 
setup.kibana.host=localhost:5601

```

And here is the error message when i run the last command

```
Index setup complete.
Loading dashboards (Kibana must be running and reachable)
Exiting: error connecting to Kibana: fail to get the Kibana version: HTTP GET request to 
http://localhost:5601/api/status fails: fail to execute the HTTP GET request: Get 
http://localhost:5601/api/status: dial tcp [::1]:5601: connect: cannot assign requested address. 
Response: .

```

Your help is highly appreciated.  
Thanks

---

<div class="post-metadata">

### Author: ![faec](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/faec/32/46988_2.png) [@faec](https://discuss.elastic.co/u/faec)
#### Post date: [May 29, 2019, 8:14pm UTC](https://discuss.elastic.co/t/fail-to-get-kibana-version-http-get-request-to-http-localhost-5600-api/182887/2 "2019-05-29T20:14:16Z")

</div>

It looks like you're telling filebeat that Kibana is on `localhost`, but in this context wouldn't localhost be the container running filebeat? What happens if you point filebeat at `kibana:5601` instead?

---

<div class="post-metadata">

### Author: ![faad021](https://avatars.discourse-cdn.com/v4/letter/f/9fc348/32.png) [@faad021](https://discuss.elastic.co/u/faad021)
#### Post date: [June 1, 2019, 8:49am UTC](https://discuss.elastic.co/t/fail-to-get-kibana-version-http-get-request-to-http-localhost-5600-api/182887/3 "2019-06-01T08:49:25Z")

</div>

Hi.  
It was now able to connect to kibana when I changed it to `kibana:5601`. However, it runs and disconnects after some few seconds. Any reason for this behavior ? Here is output after runnning the last command

> Index setup complete.  
> Loading dashboards (kibana must be running and reachable)  
> Loaded dashboards  
> Loaded machine learning job configurations  
> PS C:\Users\mymachine\>

---

<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: [June 29, 2019, 8:49am UTC](https://discuss.elastic.co/t/fail-to-get-kibana-version-http-get-request-to-http-localhost-5600-api/182887/4 "2019-06-29T08:49:30Z")

</div>

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