I am trying to set up an ELK stack with communication between Kibana and Elasticsearch. I am new to ELK and I am having trouble. I will present my configurations and the results that I am getting.
To start, I downloaded Kibana and Elasticsearch version 8.2. I am working on Linux. Then, I modified the file /elasticsearch/config/elasticsearch.yml. It contains this:
cluster.name: mes-elasticsearch-prod
node.name: myserver
path.data: /db/appli/data/elasticsearch
path.logs: /db/appli/logs/elasticsearch
network.host: 0.0.0.0
http.port: 9206
transport.port: 9306
discovery.seed_hosts: ["myserver:9306"]
cluster.initial_master_nodes: ["myserver"]
xpack.security.enabled: false
Next, I modified my file /kibana/config/kibana.yml:
server.port: 5606
server.host: "muserver"
server.name: "myserver"
elasticsearch.hosts: ["http://myserver:9206"]
elasticsearch.pingTimeout: 15000
elasticsearch.requestTimeout: 300000
elasticsearch.shardTimeout: 300000
pid.file: "/db/appli/tmp/kibana.pid"
To launch my applications, I enter the following commands:
-
/home/appli/elasticsearch/bin/elasticsearch -p /db/appli/tmp/elasticsearch.pid -d
-
/db/appli/bin/kibana-8.2.0/bin/kibana -c /db/appli/bin/kibana-8.2.0/config/kibana.yml &
Elasticsearch is working well, when I go to the URL: http://myserver:9206/ I see this:
{
"name" : "myserver",
"cluster_name" : "mes-elasticsearch-prod",
"cluster_uuid" : "_na_",
"version" : {
"number" : "8.2.0",
"build_flavor" : "default",
"build_type" : "tar",
"build_hash" : "b174af68dd9f4ac4d25875e9381ffe2b9282c5",
"build_date" : "2022-04-20T10:35:10.180408517Z",
"build_snapshot" : false,
"lucene_version" : "9.1.0",
"minimum_wire_compatibility_version" : "7.17.0",
"minimum_index_compatibility_version" : "7.0.0"
},
"tagline" : "You Know, for Search"
}
However, Kibana is not working. On the URL, it says: "Kibana server is not ready yet." Then the interface stops working and I have the following logs:
[2024-01-10T16:17:21.786+01:00][FATAL][root] ResponseError: master_not_discovered_exception: [master_not_discovered_exception] Reason: null
at KibanaTransport.request (/db/appli/bin/kibana-8.2.0/node_modules/@elastic/transport/lib/Transport.js:476:27)
at runMicrotasks (<anonymous>)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at KibanaTransport.request (/db/appli/bin/kibana-8.2.0/src/core/server/elasticsearch/client/create_transport.js:58:16)
at Cluster.getSettings (/db/appli/bin/kibana-8.2.0/node_modules/@elastic/elasticsearch/lib/api/api/cluster.js:157:16)
at isInlineScriptingEnabled (/db/appli/bin/kibana-8.2.0/src/core/server/elasticsearch/is_scripting_enabled.js:22:20)
at ElasticsearchService.start (/db/appli/bin/kibana-8.2.0/src/core/server/elasticsearch/elasticsearch_service.js:121:32)
at Server.start (/db/appli/bin/kibana-8.2.0/src/core/server/server.js:326:32)
at Root.start (/db/appli/bin/kibana-8.2.0/src/core/server/root/index.js:69:14)
at bootstrap (/db/appli/bin/kibana-8.2.0/src/core/server/bootstrap.js:120:5)
at Command.<anonymous> (/db/appli/bin/kibana-8.2.0/src/cli/serve/serve.js:216:5)
[2024-01-10T16:17:51.794+01:00][INFO ][plugins-system.preboot] Stopping all plugins.
[2024-01-10T16:17:51.795+01:00][INFO ][plugins-system.standard] Stopping all plugins.
[2024-01-10T16:17:51.796+01:00][INFO ][plugins.monitoring.monitoring.kibana-monitoring] Monitoring stats collection is stopped
[2024-01-10T16:18:21.802+01:00][WARN ][plugins-system.standard] "eventLog" plugin didn't stop in 30sec., move on to the next.
FATAL ResponseError: master_not_discovered_exception: [master_not_discovered_exception] Reason: null
Can you please help me? I'm stuck and I think the issue shouldn't be too complicated.
Thank you in advance for your help.