Babeesh
Babeesh

Reputation: 107

Not able to load Kibana on port 5601

I have installed Elasticsearch, Logstash, Kibana and Nginx following this guide,

https://www.digitalocean.com/community/tutorials/how-to-install-elasticsearch-logstash-and-kibana-elk-stack-on-ubuntu-14-04

Elasticsearch is running on 9200

But running

curl http://localhost:5601

returns this:

curl: (7) Failed to connect to localhost port 5601: Connection refused

In kibana.yml file I configured

server.port: 5601

server.host: "127.0.0.1"

Here I also checked with localhost and aws private ip address.

And while checking the port running this:

netstat -anp | grep 5601

I am getting:

(No info could be read for "-p": geteuid()=1000 but you should be root.)

I can start kibana running:

sudo service kibana start

But while checking status using:

sudo service kibana status

I get:

kibana is not running

I haven't setup firewall and running

sudo ufw status

Returns:

Status : Inactive

I am confused, why is the kibana port not listening?

Upvotes: 5

Views: 35842

Answers (5)

Ryabchenko Alexander
Ryabchenko Alexander

Reputation: 12380

For me helped solution from https://discuss.elastic.co/t/kibana-5601-connection-refused/103641/2

 /opt/kibana/bin/kibana & disown

Upvotes: 0

StacOlem
StacOlem

Reputation: 173

This is an old question but if by any chance you are here because you are having this same situation:

I can start kibana running:

sudo service kibana start

But while checking status using:

sudo service kibana status I get:

kibana is not running

And you get the Kibana server is not ready yet with an error on Kibana logs that states: FATAL Error: Port 5601 is already in use. Another instance of Kibana may be running!

You need to check this part of documentation

For example, if you run

ps -p 1

And it gives you systemctl, you shouldn´t try to run Kibana service with sudo service kibana start.

So, first run sudo service kibana stop and then sudo systemctl start kibana.

I know this might be really obvious to some, specially with the documentation addressing the situation, yet i have been found on this situation by human oversight and hope the experience will help someone out there.

Upvotes: 1

Babeesh
Babeesh

Reputation: 107

Its running now. When I checked kibana log (vi /var/log/kibana/kibana.stderr)

Error: EACCES, permission denied '/opt/kibana/optimize/.babelcache.json'

So I changed permission for the file .babelcache.json

sudo chown -R kibana:root /opt/kibana/optimize/.babelcache.json

Then restarted kibana , and this solved the issue.

Upvotes: 3

Kobayashi
Kobayashi

Reputation: 2600

Obviously the problem is that Kibana is not running. There are several things that you could try to resolve this:

  • Try to reinstall Kibana.
  • The default settings in kibana.yml should be enough to get Kibana up and running. Just be sure that you uncomment the elasticsearch.url entry and let it point to "http://localhost:9200".
  • The other thing you could check is the Elasticsearch and Kibana version compatibility. To check if you are using the right version for them please go to this link, click on product compatibility and read the details under Supported Kibana Versions.

Upvotes: 1

avr
avr

Reputation: 4883

You can check Kibana logs for why it is not starting at all. You may find things like kibana unable to connect elasticsearch at given url.

Upvotes: 4

Related Questions