How can I configure kibana on different host?

How can I configure kibana if it run on a different host with elasticsearch and logstash?
For example my elasticsearch server is 10.1.11.111
my kibana server is 10.1.11.112
and my logstash server is 10.1.11.113 ?

In kibana.yml, I set up server.host to 10.1.11.112 and point to 10.1.11.111:9200 but it does not work. Can anyone help me ?

What do you mean by "point to 10.1.11.111"? You have to set elasticsearch.hosts config setting in your kibana.yml (including protocol and port) - see https://www.elastic.co/guide/en/kibana/current/settings.html for an example

If you already did that, can you elaborate on what exactly doesn't work?

2 Likes

Of course I did it, but the kibana server is still not ready yet

I did like this topic but my kibana and elasticsearch on different host

Did you configure your elasticsearch to listen on the IP 10.1.11.111 ?

The tutorial you shared does not make this configuration, so elasticsearch per default will only listen on the loopback address (localhost, 127.0.0.1) and will be accessible only in the local machine. [documentation]

You will need to add this line in your elasticsearch.yml.

network.host: 10.1.11.111

Change your config file and try again.

I did it too. I doubt the server can't run because I change it to discovery.type single-node.


I check the kibana system is running but not sure why It is still not ready

Please don't post pictures of text, they are difficult to read, impossible to search and replicate (if it's code), and some people may not be even able to see them :slight_smile:

Can you please post your kibana.yml and your elasticsearch.yml.. Please format your code/logs/config using the </> button, or markdown style back ticks. It helps to make things easy to read which helps us help you :slight_smile:

1 Like

here is my kibana.yml
<
'''
# Kibana is served by a back end server. This setting specifies the port to use.
server.port: 5601

# Specifies the address to which the Kibana server will bind. IP addresses and host names are both valid values.
# The default is 'localhost', which usually means remote machines will not be able to connect.
# To allow connections from remote users, set this parameter to a non-loopback address.
server.host: "10.1.11.112"

# Enables you to specify a path to mount Kibana at if you are running behind a proxy.
# Use the `server.rewriteBasePath` setting to tell Kibana if it should remove the basePath
# from requests it receives, and to prevent a deprecation warning at startup.
# This setting cannot end in a slash.
#server.basePath: ""

# Specifies whether Kibana should rewrite requests that are prefixed with
# `server.basePath` or require that they are rewritten by your reverse proxy.
# This setting was effectively always `false` before Kibana 6.3 and will
# default to `true` starting in Kibana 7.0.
#server.rewriteBasePath: false

# The maximum payload size in bytes for incoming server requests.
#server.maxPayloadBytes: 1048576

# The Kibana server's name.  This is used for display purposes.
#server.name: "your-hostname"

# The URLs of the Elasticsearch instances to use for all your queries.
elasticsearch.hosts: ["http://10.1.11.111:9200"]

# Kibana uses an index in Elasticsearch to store saved searches, visualizations and
# dashboards. Kibana creates a new index if the index doesn't already exist.
#kibana.index: ".kibana"

# The default application to load.
#kibana.defaultAppId: "home"

# If your Elasticsearch is protected with basic authentication, these settings provide
# the username and password that the Kibana server uses to perform maintenance on the Kibana
# index at startup. Your Kibana users still need to authenticate with Elasticsearch, which
# is proxied through the Kibana server.
#elasticsearch.username: "kibana_system"
#elasticsearch.password: "pass"

# Enables SSL and paths to the PEM-format SSL certificate and SSL key files, respectively.
# These settings enable SSL for outgoing requests from the Kibana server to the browser.
#server.ssl.enabled: false
#server.ssl.certificate: /path/to/your/server.crt
#server.ssl.key: /path/to/your/server.key

# Optional settings that provide the paths to the PEM-format SSL certificate and key files.
# These files are used to verify the identity of Kibana to Elasticsearch and are required when
# xpack.security.http.ssl.client_authentication in Elasticsearch is set to required.
#elasticsearch.ssl.certificate: /path/to/your/client.crt
#elasticsearch.ssl.key: /path/to/your/client.key

# Optional setting that enables you to specify a path to the PEM file for the certificate
# authority for your Elasticsearch instance.
#elasticsearch.ssl.certificateAuthorities: [ "/path/to/your/CA.pem" ]

# To disregard the validity of SSL certificates, change this setting's value to 'none'.
#elasticsearch.ssl.verificationMode: full

# Time in milliseconds to wait for Elasticsearch to respond to pings. Defaults to the value of
# the elasticsearch.requestTimeout setting.
#elasticsearch.pingTimeout: 1500

# Time in milliseconds to wait for responses from the back end or Elasticsearch. This value
# must be a positive integer.
#elasticsearch.requestTimeout: 30000

# List of Kibana client-side headers to send to Elasticsearch. To send *no* client-side
# headers, set this value to [] (an empty list).
#elasticsearch.requestHeadersWhitelist: [ authorization ]

# Header names and values that are sent to Elasticsearch. Any custom headers cannot be overwritten
# by client-side headers, regardless of the elasticsearch.requestHeadersWhitelist configuration.
#elasticsearch.customHeaders: {}

# Time in milliseconds for Elasticsearch to wait for responses from shards. Set to 0 to disable.
#elasticsearch.shardTimeout: 30000

# Logs queries sent to Elasticsearch. Requires logging.verbose set to true.
#elasticsearch.logQueries: false

# Specifies the path where Kibana creates the process ID file.
#pid.file: /var/run/kibana.pid

# Enables you to specify a file where Kibana stores log output.
#logging.dest: stdout

# Set the value of this setting to true to suppress all logging output.
#logging.silent: false

# Set the value of this setting to true to suppress all logging output other than error messages.
#logging.quiet: false

# Set the value of this setting to true to log all events, including system usage information
# and all requests.
#logging.verbose: false

# Set the interval in milliseconds to sample system and process performance
# metrics. Minimum is 100ms. Defaults to 5000.
#ops.interval: 5000

# Specifies locale to be used for all localizable strings, dates and number formats.
# Supported languages are the following: English - en , by default , Chinese - zh-CN .
#i18n.locale: "en"

'''
/>

here is my elasticsearch.yml
<
'''

======================== Elasticsearch Configuration =========================

#
# NOTE: Elasticsearch comes with reasonable defaults for most settings.
#       Before you set out to tweak and tune the configuration, make sure you
#       understand what are you trying to accomplish and the consequences.
#
# The primary way of configuring a node is via this file. This template lists
# the most important settings you may want to configure for a production cluster.
#
# Please consult the documentation for further information on configuration options:
# https://www.elastic.co/guide/en/elasticsearch/reference/index.html
#
# ---------------------------------- Cluster -----------------------------------
#
# Use a descriptive name for your cluster:
#
#cluster.name: my-application
#
# ------------------------------------ Node ------------------------------------
#
# Use a descriptive name for the node:
#
#node.name: node-1
#
# Add custom attributes to the node:
#
#node.attr.rack: r1
#
# ----------------------------------- Paths ------------------------------------
#
# Path to directory where to store the data (separate multiple locations by comma):
#
path.data: /var/lib/elasticsearch
#
# Path to log files:
#
path.logs: /var/log/elasticsearch
#
# ----------------------------------- Memory -----------------------------------
#
# Lock the memory on startup:
#
#bootstrap.memory_lock: true
#
# Make sure that the heap size is set to about half the memory available
# on the system and that the owner of the process is allowed to use this
# limit.
#
# Elasticsearch performs poorly when the system is swapping the memory.
#
# ---------------------------------- Network -----------------------------------
#
# Set the bind address to a specific IP (IPv4 or IPv6):
#
network.host: 10.1.11.111
#
# Set a custom port for HTTP:
#
http.port: 9200
#
# For more information, consult the network module documentation.
#
# --------------------------------- Discovery ----------------------------------
#
# Pass an initial list of hosts to perform discovery when this node is started:
# The default list of hosts is ["127.0.0.1", "[::1]"]
#
#discovery.seed_hosts: ["host1", "host2"]
#
# Bootstrap the cluster using an initial set of master-eligible nodes:
#
#cluster.initial_master_nodes: ["node-1", "node-2"]
discovery.type: single-node
# For more information, consult the discovery and cluster formation module documentation.
#
# ---------------------------------- Gateway -----------------------------------
#
# Block initial recovery after a full cluster restart until N nodes are started:
#
#gateway.recover_after_nodes: 3
#
# For more information, consult the gateway module documentation.
#
# ---------------------------------- Various -----------------------------------
#
# Require explicit names when deleting indices:
#
#action.destructive_requires_name: true

'''
/>

Thanks, that looks good at a quick glance.

What do your Kibana logs show?

what is kibana logs ? do you mean the server? I still can't access kibana from remote server and it say "kibana server is not ready yet"

From /var/log/kibana/kibana.log.

I have no such file yet. No kibina folder in /var/log/

Can you post the text output from the startup command, rather than the image of it? There's important information that is missing from that.

here
'''
kibana.service - Kibana
Loaded: loaded (/etc/systemd/system/kibana.service; enabled; vendor preset: disabled)
Active: active (running) since Mon 2021-01-04 04:17:49 EST; 17h ago
Main PID: 111308 (node)
Tasks: 11 (limit: 49359)
Memory: 170.3M
CGroup: /system.slice/kibana.service
└─111308 /usr/share/kibana/bin/../node/bin/node /usr/share/kibana/bin/../src/cli/dist

Jan 04 21:33:06 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:06Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
Jan 04 21:33:09 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:09Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
Jan 04 21:33:13 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:13Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
Jan 04 21:33:18 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:18Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
Jan 04 21:33:22 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:22Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
Jan 04 21:33:25 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:25Z","tags":["warning","elasticsearch","monitoring"],"pid":11130>
Jan 04 21:33:25 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:25Z","tags":["warning","elasticsearch","monitoring"],"pid":11130>
Jan 04 21:33:25 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:25Z","tags":["warning","plugins","licensing"],"pid":111308,"mess>
Jan 04 21:33:28 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:28Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
Jan 04 21:33:31 localhost.localdomain kibana[111308]: {"type":"log","@timestamp":"2021-01-05T02:33:31Z","tags":["error","elasticsearch","data"],"pid":111308,"messa>
lines 1-19/19 (END)...skipping...

'''

You're still missing all the text after this unfortunately.

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