I work with Elastin in CentOS 6
Now migrate on CentOS 7
/etc/elasticsearch/elasticsearch.yml
cluster.name: my-application
node.name: node-1
path.data: /var/lib/elasticsearch
path.logs: /var/log/elasticsearch
network.host: 0.0.0.0
http.port: 9200
index.number_of_shards: 1
index.number_of_replicas: 0
/etc/init.d/elasticsearch start
Starting elasticsearch (via systemctl): [ OK ]
But
service --status-all
● elasticsearch.service - Elasticsearch
Loaded: loaded (/usr/lib/systemd/system/elasticsearch.service; disabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Вс 2017-11-19 18:24:02 MSK; 23min ago
Docs: http://www.elastic.co
Process: 7994 ExecStart=/usr/share/elasticsearch/bin/elasticsearch -p ${PID_DIR}/elasticsearch.pid --quiet (code=exited, status=1/FAILURE)
Main PID: 7994 (code=exited, status=1/FAILURE)
nov 19 18:23:57 localhost.localdomain systemd[1]: Started Elasticsearch.
nov 19 18:23:57 localhost.localdomain systemd[1]: Starting Elasticsearch...
nov 19 18:24:02 localhost.localdomain systemd[1]: elasticsearch.service: main process exited, code=exited, status=1/FAILURE
nov 19 18:24:02 localhost.localdomain systemd[1]: Unit elasticsearch.service entered failed state.
nov 19 18:24:02 localhost.localdomain systemd[1]: elasticsearch.service failed.
File /var/log/elasticsearch/my-application.log
[2017-11-19T21:17:39,768][INFO ][o.e.n.Node ] [node-1] initializing ...
[2017-11-19T21:17:39,911][INFO ][o.e.e.NodeEnvironment ] [node-1] using [1] data paths, mounts [[/ (rootfs)]], net usable_space [24.9gb],
net total_space [32.5gb], types [rootfs]
[2017-11-19T21:17:39,911][INFO ][o.e.e.NodeEnvironment ] [node-1] heap size [1007.3mb], compressed ordinary object pointers [true]
[2017-11-19T21:17:39,913][INFO ][o.e.n.Node ] [node-1] node name [node-1], node ID [noTqWFoNRvO3lthH1-4NRA]
[2017-11-19T21:17:39,913][INFO ][o.e.n.Node ] [node-1] version[6.0.0], pid[11765], build[8f0685b/2017-11-10T18:41:22.859Z], OS
[Linux/3.10.0-693.el7.x86_64/amd64], JVM[Oracle Corporation/OpenJDK 64-Bit Server VM/1.8.0_151/25.151-b12]
[2017-11-19T21:17:39,913][INFO ][o.e.n.Node ] [node-1] JVM arguments [-Xms1g, -Xmx1g, -XX:+UseConcMarkSweepGC, -XX:CMSInitiati
ngOccupancyFraction=75, -XX:+UseCMSInitiatingOccupancyOnly, -XX:+AlwaysPreTouch, -Xss1m, -Djava.awt.headless=true, -Dfile.encoding=UTF-8, -D
jna.nosys=true, -XX:-OmitStackTraceInFastThrow, -Dio.netty.noUnsafe=true, -Dio.netty.noKeySetOptimization=true, -Dio.netty.recycler.maxCapac
ityPerThread=0, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -XX:+HeapDumpOnOutOfMemoryError, -XX:HeapDumpPath=/var/lib/ela
sticsearch, -Des.path.home=/usr/share/elasticsearch, -Des.path.conf=/etc/elasticsearch]
[2017-11-19T21:17:41,229][INFO ][o.e.p.PluginsService ] [node-1] loaded module [aggs-matrix-stats]
[2017-11-19T21:17:41,229][INFO ][o.e.p.PluginsService ] [node-1] loaded module [analysis-common]
[2017-11-19T21:17:41,230][INFO ][o.e.p.PluginsService ] [node-1] loaded module [ingest-common]
[2017-11-19T21:17:41,230][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-expression]
[2017-11-19T21:17:41,230][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-mustache]
[2017-11-19T21:17:41,230][INFO ][o.e.p.PluginsService ] [node-1] loaded module [lang-painless]
[2017-11-19T21:17:41,231][INFO ][o.e.p.PluginsService ] [node-1] loaded module [parent-join]
[2017-11-19T21:17:41,231][INFO ][o.e.p.PluginsService ] [node-1] loaded module [percolator]
[2017-11-19T21:17:41,231][INFO ][o.e.p.PluginsService ] [node-1] loaded module [reindex]
[2017-11-19T21:17:41,231][INFO ][o.e.p.PluginsService ] [node-1] loaded module [repository-url]
[2017-11-19T21:17:41,231][INFO ][o.e.p.PluginsService ] [node-1] loaded module [transport-netty4]
[2017-11-19T21:17:41,231][INFO ][o.e.p.PluginsService ] [node-1] loaded module [tribe]
[2017-11-19T21:17:41,232][INFO ][o.e.p.PluginsService ] [node-1] no plugins loaded
[2017-11-19T21:17:42,062][WARN ][o.e.c.s.SettingsModule ] [node-1]
*************************************************************************************
Found index level settings on node level configuration.
Since elasticsearch 5.x index level settings can NOT be set on the nodes
configuration like the elasticsearch.yaml, in system properties or command line
arguments.In order to upgrade all indices the settings must be updated via the
/${index}/_settings API. Unless all settings are dynamic all indices must be closed
in order to apply the upgradeIndices created in the future should use index templates
to set default values.
Please ensure all required values are updated on all indices by executing:
curl -XPUT 'http://localhost:9200/_all/_settings?preserve_existing=true' -d '{
"index.number_of_replicas" : "0",
"index.number_of_shards" : "1"
}'
*************************************************************************************
Help! ;(