Hello!
How i can change messages data path?
After change path, i can’t to start elasticsearch
Maybe provide some details, so that people can try to help you.
Service status -
elasticsearch.service - Elasticsearch Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; enabled; vendor preset: disabled) Active: failed (Result: exit-code) since Sat 2018-02-03 21:40:11 +06; 1h 6min ago Docs: http://www.elastic.co Process: 15083 ExecStart=/usr/share/elasticsearch/bin/elasticsearch -p ${PID_DIR}/elasticsearch.pid --quiet -Edefault.path.logs=${LOG_DIR} -Edefault.path.data=${DATA_DIR} -Edefault.path.conf=${CONF_DIR} (code=exited, status=1/FAILURE) Process: 15081 ExecStartPre=/usr/share/elasticsearch/bin/elasticsearch-systemd-pre-exec (code=exited, status=0/SUCCESS) Main PID: 15083 (code=exited, status=1/FAILURE) Feb 03 21:40:09 log.nat.kz systemd[1]: Starting Elasticsearch... Feb 03 21:40:09 log.nat.kz systemd[1]: Started Elasticsearch. Feb 03 21:40:11 log.nat.kz systemd[1]: elasticsearch.service: main process exited, code=exited, status=1/FAILURE Feb 03 21:40:11 log.nat.kz systemd[1]: Unit elasticsearch.service entered failed state. Feb 03 21:40:11 log.nat.kz systemd[1]: elasticsearch.service failed.
I set chmod 777 and chown elasticsearch:elasticsearch to dir.
My elasticsearch.yml file -
GNU nano 2.3.1 File: /etc/elasticsearch/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:# Elasticsearch Guide | Elastic
# # ---------------------------------- Cluster -----------------------------------
#
# Use a descriptive name for your cluster: # cluster.name: graylog
#
# ------------------------------------ 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/data
# Path to log files: #
#path.logs: /path/to/logs #
# ----------------------------------- 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: 192.168.0.1
#
# Set a custom port for HTTP:
#
#http.port: 9200
#
# For more information, consult the network module documentation.
#
# --------------------------------- Discovery ----------------------------------
What’s in the logs of that Elasticsearch node?
[root@log ~]# tailf /var/log/elasticsearch/graylog.log
at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84) ~[elasticsearch-5.6.6.jar:5.6.6]
Caused by: java.lang.IllegalStateException: detected index data in default.path.data [/var/lib/elasticsearch] where there should not be any; check the logs for details
at org.elasticsearch.node.Node.checkForIndexDataInDefaultPathData(Node.java:577) ~[elasticsearch-5.6.6.jar:5.6.6]
at org.elasticsearch.node.Node.(Node.java:275) ~[elasticsearch-5.6.6.jar:5.6.6]
at org.elasticsearch.node.Node.(Node.java:245) ~[elasticsearch-5.6.6.jar:5.6.6]
at org.elasticsearch.bootstrap.Bootstrap$5.(Bootstrap.java:233) ~[elasticsearch-5.6.6.jar:5.6.6]
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:233) ~[elasticsearch-5.6.6.jar:5.6.6]
at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:342) ~[elasticsearch-5.6.6.jar:5.6.6]
at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:132) ~[elasticsearch-5.6.6.jar:5.6.6]
There is something weird in your elasticsearch.yml file. The cluster name is commented out, but still your log file is named by that name. Are you sure you use the provided elasticsearch.yml or that you are reading the correct log file?
How i can check it? I install by manual.
Which manual? What install method?
Official graylog man
I found file /etc/sysconfig/elasticsearch, where i can change path.data and config path, can i change data.path in this file?)
depending on your installation method you can find the place for the file here: http://docs.graylog.org/en/2.4/pages/configuration/file_location.html
What is mean JVM settings?
What is mean JVM settings?
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.