Elastic search not starting

 at org.elasticsearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:234) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:234) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:434) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:166) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:157) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:77) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:112) ~[elasticsearch-cli-7.16.3.jar:7.16.3]
                at org.elasticsearch.cli.Command.main(Command.java:77) ~[elasticsearch-cli-7.16.3.jar:7.16.3]
                at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:122) ~[elasticsearch-7.16.3.jar:7.16.3]
                at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:80) ~[elasticsearch-7.16.3.jar:7.16.3]

type or paste code here# ----------------------------------- 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 -----------------------------------
#
# By default Elasticsearch is only accessible on localhost. Set a different
# address here to expose this node on the network:
#
network.host: my_ip address
#
# By default Elasticsearch listens for HTTP traffic on the first free port it
# finds starting at 9200. Set a specific HTTP port here:
#
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"]
#
# Bootstrap the cluster using an initial set of master-eligible nodes:
#
cluster.initial_master_nodes: ["node-1"]
#
# For more information, consult the discovery and cluster formation module documentation.
#
# ---------------------------------- Various -----------------------------------
#
# Require explicit names when deleting indices:
#
#action.destructive_requires_name: true
#
# ---------------------------------- Security ----------------------------------
#
#                                 *** WARNING ***
#
# Elasticsearch security features are not enabled by default.
# These features are free, but require configuration changes to enable them.
# This means that users don’t have to provide credentials and can get full access
# to the cluster. Network connections are also not encrypted.
#
# To protect your data, we strongly encourage you to enable the Elasticsearch security features.
# Refer to the following documentation for instructions.
#
# https://www.elastic.co/guide/en/elasticsearch/reference/7.16/configuring-stack-security.html


@warkolm The bot does not seem very good at identifying versions used. Is this something that can be fixed?

Yeah, we have disabled it.

Can anyone help me on this?
@warkolm

Please provide larger section of the logs around the error.

[2022-01-20T14:46:37,109][INFO ][o.e.n.Node               ] [node-1] version[7.16.3], pid[90652], build[default/rpm/4e6e4eab2297e949ec994e688dad46290d018022/2022-01-06T23:43:02.825887787Z], OS[Linux/3.10.0-1160.45.1.el7.x86_64/amd64], JVM[Eclipse Adoptium/OpenJDK 64-Bit Server VM/17.0.1/17.0.1+12]
[2022-01-20T14:46:37,120][INFO ][o.e.n.Node               ] [node-1] JVM home [/usr/share/elasticsearch/jdk], using bundled JDK [true]
[2022-01-20T14:46:37,121][INFO ][o.e.n.Node               ] [node-1] JVM arguments [-Xshare:auto, -Des.networkaddress.cache.ttl=60, -Des.networkaddress.cache.negative.ttl=10, -XX:+AlwaysPreTouch, -Xss1m, -Djava.awt.headless=true, -Dfile.encoding=UTF-8, -Djna.nosys=true, -XX:-OmitStackTraceInFastThrow, -XX:+ShowCodeDetailsInExceptionMessages, -Dio.netty.noUnsafe=true, -Dio.netty.noKeySetOptimization=true, -Dio.netty.recycler.maxCapacityPerThread=0, -Dio.netty.allocator.numDirectArenas=0, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -Dlog4j2.formatMsgNoLookups=true, -Djava.locale.providers=SPI,COMPAT, --add-opens=java.base/java.io=ALL-UNNAMED, -XX:+UseG1GC, -Djava.io.tmpdir=/tmp/elasticsearch-9834413976270902310, -XX:+HeapDumpOnOutOfMemoryError, -XX:+ExitOnOutOfMemoryError, -XX:HeapDumpPath=/var/lib/elasticsearch, -XX:ErrorFile=/var/log/elasticsearch/hs_err_pid%p.log, -Xlog:gc*,gc+age=trace,safepoint:file=/var/log/elasticsearch/gc.log:utctime,pid,tags:filecount=32,filesize=64m, -Xms7933m, -Xmx7933m, -XX:MaxDirectMemorySize=4160749568, -XX:G1HeapRegionSize=4m, -XX:InitiatingHeapOccupancyPercent=30, -XX:G1ReservePercent=15, -Des.path.home=/usr/share/elasticsearch, -Des.path.conf=/etc/elasticsearch, -Des.distribution.flavor=default, -Des.distribution.type=rpm, -Des.bundled_jdk=true]
[2022-01-20T14:46:46,414][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [aggs-matrix-stats]
[2022-01-20T14:46:46,415][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [analysis-common]
[2022-01-20T14:46:46,416][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [constant-keyword]
[2022-01-20T14:46:46,417][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [frozen-indices]
[2022-01-20T14:46:46,417][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [ingest-common]
[2022-01-20T14:46:46,418][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [ingest-geoip]
[2022-01-20T14:46:46,419][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [ingest-user-agent]
[2022-01-20T14:46:46,419][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [kibana]
[2022-01-20T14:46:46,420][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [lang-expression]
[2022-01-20T14:46:46,421][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [lang-mustache]
[2022-01-20T14:46:46,422][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [lang-painless]
[2022-01-20T14:46:46,424][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [legacy-geo]
[2022-01-20T14:46:46,425][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [mapper-extras]
[2022-01-20T14:46:46,426][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [mapper-version]
[2022-01-20T14:46:46,427][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [parent-join]
[2022-01-20T14:46:46,428][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [percolator]
[2022-01-20T14:46:46,428][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [rank-eval]
[2022-01-20T14:46:46,429][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [reindex]
[2022-01-20T14:46:46,429][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [repositories-metering-api]
[2022-01-20T14:46:46,430][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [repository-encrypted]
[2022-01-20T14:46:46,431][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [repository-url]
[2022-01-20T14:46:46,432][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [runtime-fields-common]
[2022-01-20T14:46:46,432][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [search-business-rules]
[2022-01-20T14:46:46,433][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [searchable-snapshots]
[2022-01-20T14:46:46,434][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [snapshot-repo-test-kit]
[2022-01-20T14:46:46,435][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [spatial]
[2022-01-20T14:46:46,435][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [systemd]
[2022-01-20T14:46:46,436][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [transform]
[2022-01-20T14:46:46,437][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [transport-netty4]
[2022-01-20T14:46:46,437][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [unsigned-long]
[2022-01-20T14:46:46,438][INFO ][o.e.p.PluginsService     ] [node-1] loaded module [vector-tile]

Hi @Christian_Dahlqvist

That does not seem to include the full error.

elasticsearch.service - Elasticsearch
   Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; vendor preset: disabled)
   Active: failed (Result: exit-code) since Thu 2022-01-20 15:07:09 IST; 24h ago
     Docs: https://www.elastic.co
  Process: 91922 ExecStart=/usr/share/elasticsearch/bin/systemd-entrypoint -p ${PID_DIR}/elasticsearch.pid --quiet (code=exited, status=1/FAILURE)
 Main PID: 91922 (code=exited, status=1/FAILURE)

Jan 20 15:07:08 hib-vm-siemlogcol systemd-entrypoint[91922]: at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:77)
Jan 20 15:07:08 hib-vm-siemlogcol systemd-entrypoint[91922]: at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:112)
Jan 20 15:07:08 hib-vm-siemlogcol systemd-entrypoint[91922]: at org.elasticsearch.cli.Command.main(Command.java:77)
Jan 20 15:07:08 hib-vm-siemlogcol systemd-entrypoint[91922]: at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:122)
Jan 20 15:07:08 hib-vm-siemlogcol systemd-entrypoint[91922]: at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:80)
Jan 20 15:07:08 hib-vm-siemlogcol systemd-entrypoint[91922]: For complete error details, refer to the log at /var/log/elasticsearch/elasticsearch.log
Jan 20 15:07:09 hib-vm-siemlogcol systemd[1]: elasticsearch.service: main process exited, code=exited, status=1/FAILURE
Jan 20 15:07:09 hib-vm-siemlogcol systemd[1]: Failed to start Elasticsearch.
Jan 20 15:07:09 hib-vm-siemlogcol systemd[1]: Unit elasticsearch.service entered failed state.
Jan 20 15:07:09 hib-vm-siemlogcol systemd[1]: elasticsearch.service failed.

What is the full error and surrounding lines from the Elasticsearch logs?

I have sent the full error @Christian_Dahlqvist

Please post it here so the community can see and learn from it.

1 Like

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