Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can't start elastic search on CentOS Linux release 7.5.1804 (Core) #36

Closed
ajithcofficial opened this issue Nov 3, 2018 · 2 comments
Closed

Comments

@ajithcofficial
Copy link

[ajith@barinlab portland-metro]$ whoami
ajith
[ajith@barinlab portland-metro]$ id -u ajith
1000
[ajith@barinlab portland-metro]$ id -g ajith
1000

userid is same as specified in .env file

[ajith@barinlab portland-metro]$ cat .env 
COMPOSE_PROJECT_NAME=pelias
DOCKER_USER=1000
DATA_DIR=/data
[ajith@barinlab portland-metro]$ 

I executed the following commands in the given order to setup a pelias geocoder.

[ajith@barinlab portland-metro]$ sudo mkdir /code /data

[ajith@barinlab portland-metro]$ sudo chown 1000:1000 /code /data

[ajith@barinlab portland-metro]$ cd /code

[ajith@barinlab portland-metro]$ git clone https://github.com/pelias/docker.git

[ajith@barinlab portland-metro]$ cd docker

[ajith@barinlab portland-metro]$ sudo ln -sf "$(pwd)/pelias" /usr/local/bin/pelias

[ajith@barinlab portland-metro]$ cd projects/portland-metro

[ajith@barinlab portland-metro]$ sed -i '/DATA_DIR/d' .env

[ajith@barinlab portland-metro]$ echo 'DATA_DIR=/data' >> .env

[ajith@barinlab portland-metro]$ mkdir -p /data/elasticsearch/data

[ajith@barinlab portland-metro]$ mkdir -p /usr/share/elasticsearch/data

[ajith@barinlab portland-metro]$ pelias compose pull

[ajith@barinlab portland-metro]$ pelias elastic start

[ajith@barinlab portland-metro]$ pelias elastic wait
waiting for elasticsearch service to come up
..........................................^C
[ajith@barinlab portland-metro]$ 

[ajith@barinlab portland-metro]$ pelias compose ps
        Name                   Command             State      Ports
-------------------------------------------------------------------
pelias_elasticsearch   /bin/bash bin/es-docker   Restarting        
[ajith@barinlab portland-metro]$ 

[ajith@barinlab portland-metro]$ pelias compose logs
Attaching to pelias_elasticsearch
elasticsearch_1  | [2018-11-02T17:39:55,876][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
elasticsearch_1  | org.elasticsearch.bootstrap.StartupException: java.lang.IllegalStateException: Unable to access 'path.data' (/usr/share/elasticsearch/data)
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:136) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.execute(Elasticsearch.java:123) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:70) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.cli.Command.mainWithoutErrorHandling(Command.java:134) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.cli.Command.main(Command.java:90) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:91) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.main(Elasticsearch.java:84) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | Caused by: java.lang.IllegalStateException: Unable to access 'path.data' (/usr/share/elasticsearch/data)
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Security.addPath(Security.java:450) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Security.addFilePermissions(Security.java:291) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Security.createPermissions(Security.java:246) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Security.configure(Security.java:119) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:228) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Bootstrap.init(Bootstrap.java:342) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	at org.elasticsearch.bootstrap.Elasticsearch.init(Elasticsearch.java:132) ~[elasticsearch-5.6.12.jar:5.6.12]
elasticsearch_1  | 	... 6 more
.....
...
..

What step I had missed? Why I cant start elastic search? please help...

Originally posted by @ajithcofficial in #33 (comment)

@orangejulius
Copy link
Member

Hi @ajithcofficial,
Your script looks correct, so I think we have a legitimate mystery here. I have a couple ideas of things to try:

Let me know if you find anything interesting

@orangejulius
Copy link
Member

Hi @ajithcofficial,
Did you ever discover anything?

We are interested in making our docker setup as resilient as possible, so if you did, please let us know.

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants