Installing Kibana to connect to Elasticsearch production server

(Brian Anderson) #1


First post, so there is a likelihood that I may not understand how things work in connecting Kibana and Elasticsearch in a secure production environment.

So, I have a live website that has access to our closed local network. The live website connects to our elasticsearch instance which is configured in the elasticsearch.yml to be

I make a call from our live server to to make a query. This works great.

When I connect to Kibana on191.168.32.200, I get an error showing that it is not able to connect to elasticsearch on localhost:9200. This seems an obvious case since elasticsearch is configured to map to

How do I reconcile this?

On my web server I am using the Elasticsearch PHP client library to connect to the elasticsearch node which is not of course localhost in relation to the live server. It would be insecure to install elasticsearch directly on a live server that has access to the open web. Therefore a client using the PHP API would never use localhost:9200. Am I right?

Of course If I do change my elasticsearch.yml to point to, then Kibana comes up properly, but then... bang, no remote access from my live client server.

(Mark Walkom) #2

What config changes have you made to ES and KB around the network interfaces it listens to?

(Brian Anderson) #4

Only changes to the elasticsearch.yml and kibana.yml

elasticsearch.url: ""

(Brian Anderson) #5

Was that just a rhetorical question about the config changes, or was there anything else that could be adjusted?

(Mark Walkom) #6

No, I just have a day job that I need to do as well :wink:
And having the info means someone else might be able to jump in and help.

But there doesn't appear to be anything wrong with that. Can you curl from the KB host?

(Brian Anderson) #7

Sorry, wasn't meant as a criticism, just wondering it it meant there was something to be adjusted, or if it was just for general information sake.

And yes, you are right... more info means others can jump in. Thank you

The answer is yes, If I curl from the local machine, I get the elasticsearch server info. If I curl, I get the Kibana authentication notification.

Thanks again,


(Mark Walkom) #8

And is the local machine, aka the machine with ES and KB running on it?
Just wanting to make sure I am clear on things :wink:

(Brian Anderson) #9

Yes, the machine at that IP is also the machine that ES and KB are installed on.

(Mark Walkom) #10

It's not a firewall is it?
What if you stop ES and KB, start ES, wait for green, then start KB?

(Brian Anderson) #11

Well, I disabled ufw and verified it was inactive for testing purposes. I stopped both ES and KB, then restarted ES and then KB. Still, I am getting the same error.

Status: Red

plugin:kibana Ready
plugin:elasticsearch Unable to connect to Elasticsearch at http://localhost:9200.
plugin:kbn_vislib_vis_types Ready
plugin:markdown_vis Ready
plugin:metric_vis Ready
plugin:spyModes Ready
plugin:statusPage Ready
plugin:table_vis Ready

(Mark Walkom) #12

Can you paste (or use gist/pastebin/etc) the entire KB config file, as it is, comments and all?

(Brian Anderson) #13

(Mark Walkom) #14

You haven't uncommented elasticsearch.url?

(Brian Anderson) #15

what in that entire file needs to be uncommented and what remains commented?

(Brian Anderson) #16

now I restarted all my services and cant recall my kibana dashboard password. I need to figure how to reset.

(Mark Walkom) #17

You need to edit it and remove the # in front of "", then restart KB.

(system) #18

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